$val){ if ($val !== null) $data[$key] = $val; } if(sizeof($data) < 1){ return null; } return $data; } /** * @return mixed */ public function getId() { return $this->id; } /** * @param mixed $id */ public function setId($id) { $this->id = $id; } /** * @return mixed */ public function getTitle() { return $this->title; } /** * @param mixed $title */ public function setTitle($title) { $this->title = $title; } /** * @return mixed */ public function getRequired() { return $this->required; } /** * @param mixed $required */ public function setRequired($required) { $this->required = $required; } /** * @return mixed */ public function getNeedSign() { return $this->needSign; } /** * @param mixed $needSign */ public function setNeedSign($needSign) { $this->needSign = $needSign; } }