/** * Generate an empty object with the fields initialized to null. * * @return array Empty data object. */ public function createEmptyObject() { $data = ObjectUtil::createEmptyObject($this->_objType); if ($data) { $this->_objData = $data; } return $this->_objData; }
/** * Generate an empty object with the fields initialized to null. * * @param integer $num Number of empty objects. * * @return array The generated object. */ public function generateEmptyObjectArray($num = 1) { $item = ObjectUtil::createEmptyObject($this->_objType); if ($item) { $data = array(); for ($i = 0; $i < $num; $i++) { $data[] = $item; } $this->_objData = $data; } return $this->_objData; }