/** * Retrieves parent object * * @return RM_Anketa_Entity **/ protected function _getParent() { $parent_type = @$this->_mapper->parent_type($this->type()); if (!$parent_type) { return NULL; } if (is_null($this->_parent)) { $this->_parent = $this->_mapper->loadById($parent_type, $this->{$parent_type . '_id'}); } return $this->_parent; }
/** * @see RM_Anketa_Mapper::parent_type() **/ public function parent_type($name) { return $this->_mapper->parent_type($name); }