Пример #1
0
		void FindChildren(AssadBase parent)
		{
			if (parent.Children != null)
				foreach (var child in parent.Children)
				{
					_allChildren.Add(child);
					FindChildren(child);
				}
		}
Пример #2
0
		void AddChild(Assad.MHconfigTypeDevice innerDevice, AssadBase parent)
		{
			if (innerDevice.device != null)
				foreach (var innerChild in innerDevice.device)
				{
					AssadBase child = Create(innerChild);
					child.Parent = parent;
					parent.Children.Add(child);
					child.SetInnerDevice(innerChild);
					AddChild(innerChild, child);
				}
		}