public void Render(object data, TextWriter writer, TemplateLocator templateLocator, IValueProviderCollection valueProviders) { var context = new RenderContext(this, data, writer, templateLocator, valueProviders); Render(context); writer.Flush(); }
public RenderContext(Section section, object data, TextWriter writer, TemplateLocator templateLocator, IValueProviderCollection valueProviders) { _sectionStack.Push(section); _dataStack.Push(data); _writer = writer; _templateLocator = templateLocator; _valueProviders = valueProviders; _includeLevel = 0; }