$val){ if ($val !== null) $data[$key] = $val; } if(sizeof($data) < 1){ return null; } return $data; } /** * @return mixed */ public function getName() { return $this->name; } /** * @param mixed $name */ public function setName($name) { $this->name = $name; } /** * @return mixed */ public function getValue() { return $this->value; } /** * @param mixed $value */ public function setValue($value) { $this->value = $value; } /** * @return mixed */ public function getRequired() { return $this->required; } /** * @param mixed $required */ public function setRequired($required) { $this->required = $required; } /** * @return mixed */ public function getType() { return $this->type; } /** * @param mixed $type */ public function setType($type) { $this->type = $type; } }