Exemplo n.º 1
0
 /**
  * @param Node $child
  */
 public function appendChild(Node $child)
 {
     if ($this->lastChild) {
         $this->lastChild->insertAfter($child);
     } else {
         $child->detach();
         $child->setParent($this);
         $this->lastChild = $this->firstChild = $child;
     }
 }