protected SegmentedDocument TransformTemplate(string prefix, Template template, string suffix) { var doc = new SegmentedDocument(new TextDocument("")); doc.Replace(0, 0, serialiser.Deserialise(prefix)); doc.Replace(doc.TextLength, 0, template.TemplateDocument); doc.Replace(doc.TextLength, 0, serialiser.Deserialise(suffix)); return(doc); }
protected SegmentedDocument TransformTemplate(string prefix, SegmentedDocument doc, string suffix) { doc.Replace(0, 0, serialiser.Deserialise(prefix)); doc.Replace(doc.TextLength, 0, serialiser.Deserialise(suffix)); return(doc); }