public function __call($method, $params)
 {
     if ($this->_isMagicFind($method)) {
         array_unshift($params, $this->_magicFindType($method));
         return call_user_func_array(array($this, '_magicFind'), $params);
     }
     return parent::__call($method, $params);
 }
Example #2
0
 /**
  * Table::__call()
  *
  * @param string $method Name of method to call.
  * @param array $params Parameters for the method.
  * @return mixed Whatever is returned by called method
  */
 public function __call($method, $params)
 {
     list($entity, $method) = $this->_analyzeMethodName($method);
     $return = parent::__call($method, $params);
     if ($entity && !is_null($return)) {
         $return = $this->convertToEntities($return);
     }
     return $return;
 }