/// <summary> /// Recursively builds a data context tree for a render context /// </summary> private void AddDataContext(IRenderContext renderContext, IDataContext dataContext) { if (_staticSupplies != null) { for (var i = 0; i < _staticSupplies.Length; i++) { _staticSupplies[i].Supply(renderContext, dataContext); } } renderContext.AddDataContext(Id, dataContext); if (_children != null) { for (var i = 0; i < _children.Length; i++) { _children[i].BuildDataContextTree(renderContext, dataContext); } } }