private void UpdateContexts(GeographicArea <TAgent> context) { if (context is Region <TAgent> asGroup) { foreach (var child in asGroup.ChildContexts) { UpdateContexts(child.Value); } return; } var asLocal = (TLocalArea)context; asLocal.Day = Day; asLocal.Date = Date; UpdateLocalContext(asLocal); }
internal void AddChild(GeographicArea <T> childContext) { ChildContexts.Add(childContext.Name, childContext); childContext.Parent = this; }