示例#1
0
        async Task <IList <ContentTranslationDto> > BreakIntoAttributeAsync(IEnumerable <ContentTranslationDto> paragraphedContents, FontAttribute attribute, string regexPattern, string attributeMarkStart, string attributeMarkEnd)
        {
            var contentBuilderParams = new ContentBuilderParameters(attribute);

            fontAttributeContentFormatter = new FontAttributeContentFormatter();
            var contentBuilder = new ContentBuilder(contentBuilderParams, fontAttributeContentFormatter);
            var newContents    = await contentBuilder.TranslateContentAsync(paragraphedContents, attributeMarkStart, attributeMarkEnd, regexPattern);


            return(newContents.ToList());
        }
示例#2
0
 public ContentBuilder(ContentBuilderParameters contentParameters, ContentFormatter contentFormatter)
 {
     this.contentParameters = contentParameters;
     this.contentFormatter  = contentFormatter;
 }
示例#3
0
 public ContentBuilder(ContentFormatter contentFormatter)
 {
     this.contentFormatter = contentFormatter;
     contentParameters     = new ContentBuilderParameters();
 }