示例#1
0
 public function __clone()
 {
     parent::__clone();
     foreach ($this->arrLegends as $strName => $objLegend) {
         $this->arrLegends[$strName] = clone $objLegend;
         $this->arrLegends[$strName]->setPalette($this);
     }
 }
 /**
  * Clone all properties as well
  */
 public function __clone()
 {
     parent::__clone();
     foreach ($this->arrProperties as $strName => $objProperty) {
         $this->arrProperties[$strName] = clone $objProperty;
         $this->arrProperties[$strName]->setParent($this);
     }
 }
示例#3
0
 /**
  * Prepare argument so that an array of name and the object is passed
  *
  * @param PropertyContainerInterface $objReference
  * @param Node|string $node
  * @param bool $blnNull return null if property does not exists
  *
  * @return array[string|Property|null]
  */
 public static function argument(PropertyContainerInterface $objReference, $node, $blnNull = true)
 {
     return Node::prepareArgument($objReference, $node, $blnNull, 'Property');
 }
示例#4
0
 /**
  * Test if element has same DataContainer as root
  *
  * @param Node $node
  *
  * @return bool
  */
 public function hasSameDataContainer(Node $node)
 {
     return $this->getDataContainer() == $node->getDataContainer();
 }