예제 #1
0
파일: Node.php 프로젝트: talesoft/tale-tree
 /**
  *
  */
 public function __clone()
 {
     parent::__clone();
     $children = $this->children;
     $this->children = [];
     foreach ($children as $child) {
         $this->appendChild(clone $child);
     }
 }
예제 #2
0
파일: Text.php 프로젝트: talesoft/tale-dom
 /**
  * Text constructor.
  *
  * @param string $text
  * @param NodeInterface $parent
  */
 public function __construct($text, NodeInterface $parent = null)
 {
     parent::__construct($parent);
     $this->text = $text;
 }