Exemplo n.º 1
0
 public function __construct($name = null, $value = null)
 {
     \tool::fprint("Creating " . get_called_class() . ":{$name}(" . (is_a($value, __CLASS__) ? $value->value : $value) . ")");
     parent::__construct();
     $this->name = $name;
     $this->value = is_a($value, __CLASS__) ? $value->value : $value;
 }
Exemplo n.º 2
0
 public function __construct($name = null, $content = array())
 {
     \tool::fprint("Creating " . get_called_class() . (count($content) ? " with " . count($content) . " elements" : ''));
     parent::__construct();
     $this->name = $name;
     $this->content = $content ? (array) $content : array();
 }