Пример #1
0
 /// <summary>
 /// 添加子节点
 /// </summary>
 /// <param name="component"></param>
 public abstract void Add(Component component);
Пример #2
0
 /// <summary>
 /// 删除指定的节点
 /// </summary>
 /// <param name="component"></param>
 public abstract void RemoveAt(Component component);
Пример #3
0
 public override void Add(Component component)
 {
     throw new NotSupportedException("不支持Add操作!");
 }
Пример #4
0
 public override void RemoveAt(Component component)
 {
     throw new NotSupportedException("不支持RemoveAt操作!");
 }
Пример #5
0
 public override void Add(Component component)
 {
     _componentList.Add(component);
 }
Пример #6
0
 public override void RemoveAt(Component component)
 {
     _componentList.Remove(component);
 }
Пример #7
0
 /// <inheritdoc />
 public override void Add(Component c)
 {
     Console.WriteLine("leaf can't not add");
 }
Пример #8
0
 /// <inheritdoc />
 public override void Remove(Component c)
 {
     Console.WriteLine("leaf can't not remove");
 }
Пример #9
0
 public abstract void Remove(Component c);
Пример #10
0
 public abstract void Add(Component c);
Пример #11
0
 /// <inheritdoc />
 public override void Remove(Component c)
 {
     components.Remove(c);
 }
Пример #12
0
 public Composite Add2Self(Component c)
 {
     components.Add(c);
     return(this);
 }
Пример #13
0
 /// <inheritdoc />
 public override void Add(Component c)
 {
     components.Add(c);
 }