public void AddChild(IsContainable child) { if (child.Parent == this.self) { return; } if (child.Parent != null) { child.Parent.RemoveChild(child); } this.children.Add(child); child.Parent = this.self; }
public void RemoveChild(IsContainable child) { this.children.Remove(child); child.Parent = null; }