private ITagPair CreateTagPair(ContentMatch match)
        {
            IStartTagProperties startProperties = _itemFactory.PropertiesFactory.CreateStartTagProperties(match.Value);

            startProperties.CanHide = match.MatchRule.CanHide;
            startProperties.IsSoftBreak = match.MatchRule.IsSoftBreak;
            startProperties.IsWordStop = match.MatchRule.IsWordStop;

            startProperties.DisplayText = GetDisplayName(match.Value);
            startProperties.Formatting = FormattingInflator.InflateFormatting(match.MatchRule.Formatting);
            startProperties.SegmentationHint = match.MatchRule.SegmentationHint;
            startProperties.SetMetaData(EmbeddedContentMetaKey, match.Value);

             IEndTagProperties endProperties = _itemFactory.PropertiesFactory.CreateEndTagProperties(match.Value);

            endProperties.CanHide = match.MatchRule.CanHide;
            endProperties.IsSoftBreak = match.MatchRule.IsSoftBreak;
            endProperties.IsWordStop = match.MatchRule.IsWordStop;
            endProperties.DisplayText = GetDisplayName(match.Value);
            endProperties.SetMetaData(EmbeddedContentMetaKey, match.Value);

            return _itemFactory.CreateTagPair(startProperties, endProperties);
        }
        private IAbstractMarkupData CreatePlaceholderTag(ContentMatch match)
        {
            var placeholderProps = _itemFactory.PropertiesFactory.CreatePlaceholderTagProperties(match.Value);


            placeholderProps.CanHide = match.MatchRule.CanHide;
            placeholderProps.IsSoftBreak = match.MatchRule.IsSoftBreak;
            placeholderProps.IsWordStop = match.MatchRule.IsWordStop;

            placeholderProps.DisplayText = GetDisplayName(match.Value);
            placeholderProps.SegmentationHint = match.MatchRule.SegmentationHint;
            placeholderProps.TagContent = match.Value;

            if (!string.IsNullOrEmpty(match.MatchRule.TextEquivalent))
            {
                placeholderProps.TextEquivalent = match.MatchRule.TextEquivalent;
            }
            placeholderProps.SetMetaData(EmbeddedContentMetaKey, match.Value);

            return _itemFactory.CreatePlaceholderTag(placeholderProps);
        }
 private void AddOpenTagContainer(ContentMatch match)
 {
     if (match.MatchRule.IsContentTranslatable)
     {
         ITagPair tagPair = CreateTagPair(match);
         _currentContainer.Add(tagPair);
         _currentContainer = tagPair;
     }
     else
     {
         //treat non-translatable content as locked
         ILockedContent lockedContent = CreateLockedContent();
         _currentContainer.Add(lockedContent);
         _currentContainer = lockedContent.Content;
     }
 }