Пример #1
0
 public override void RemoveChild(IElement element)
 {
     if (element.IsLocked)
     {
         throw new ElementIsLockedException(element.Name);
     }
     ChildrenList.Remove(element);
 }
Пример #2
0
 internal void ImmediatelyRemoveChild(Object2D child)
 {
     if (IsAlive)
     {
         CoreObject.RemoveChild(child.CoreObject);
         ChildrenList.Remove(child);
     }
 }
Пример #3
0
        public virtual void RemoveChild(TValue value)
        {
            var node = ChildrenList.FirstOrDefault(x => value.Equals(x.Value));

            if (node == null)
            {
                throw new InvalidOperationException(string.Format("Could not find child '{0}'.", value));
            }
            ChildrenList.Remove(node);
        }
Пример #4
0
 public void RemovedChild(Entity e)
 {
     ChildrenList.Remove(e);
 }
Пример #5
0
 /// <summary>
 /// Remove a child from this RecursiveTree
 /// </summary>
 /// <param name="child">The child to be removed</param>
 public void RemoveChild(RecursiveTree <V> child)
 {
     try { ChildrenList.Remove(child); }
     catch { throw new Exception("Child is no child of this node!"); }
 }