/** * Appends a node to the root node * * @param Node $node */ public function append(Node $node) { $this->root->append($node); }
/** * @param Node $child * @return self */ public function prepend(Node $child) { if ($this->xml) { $child->setXml($this->xml); } array_unshift($this->children, $child); }