Esempio n. 1
0
 public T setChildren(List<Element> children) {
   for (Element child : children) {
     child.parent = this;
   }
   this.children = children;
   return (T) this;
 }
Esempio n. 2
0
 public T addChild(Element element) {
   element.parent = this;
   ElementEventGenerator.triggerBeforeInsert(this, element);
   this.children.add(element);
   ElementHelper.reorderElements(this.children);
   ElementEventGenerator.triggerAfterInsert(this, element);
   return (T) this;
 }