public function __construct() { list($parent, $name) = func_get_args() + [NULL, NULL]; if ($parent !== NULL) { $parent->addComponent($this, $name); } elseif (is_string($name)) { $this->name = $name; } }
/** * @param \Venne\Forms\IFormFactory|\Closure $factory * @param string $title * @param null $type */ public function __construct($factory, $title, $type = null) { parent::__construct(); $this->factory = $factory; $this->title = $title; $this->type = $type; }