public void Build(PrintElement element, TextWriter result) { if (element != null) { IHtmlBuilder builder; if (_builders.TryGetValue(element.GetType(), out builder)) { builder.Build(this, element, result); } } }
public object Build(PrintElement element, PrintElementMetadataMap elementMetadataMap) { if (element != null) { IFlowElementBuilder builder; if (_builders.TryGetValue(element.GetType(), out builder)) { var flowElement = builder.Build(this, element, elementMetadataMap); elementMetadataMap.RemapElement(element, flowElement); return(flowElement); } } return(null); }