/** * * Checks if a data key is set. * * @param string $key The requested data key. * * @return void * */ public function __isset($key) { // if an accessor method exists, use it if (!empty($this->_access_methods[$key]['isset'])) { // use accessor method $method = $this->_access_methods[$key]['isset']; $result = $this->{$method}(); } else { // no accessor method; use parent method $result = parent::__isset($key); } // done return $result; }