public static DataMap Zip(ICollection <string> keys, ICollection <string> values) { var data = new DataMap(); var ki = keys.GetEnumerator(); var vi = values.GetEnumerator(); while (ki.MoveNext()) { data.Set(ki.Current, vi.MoveNext() ? vi.Current : ""); } return(data); }
protected virtual T RenderE(Text elem, Template tpl, DataMap data) { throw new Exception("Unsupported element."); }
public T Render(Template tpl, DataMap data = null) { return(Render(tpl.elem, tpl, data)); }