public function __call($method, $arguments) { if ($this->dataSource && $this->dataSource->ID) { $name = $this->realisedName . LayerManager::FIELD_SEPARATOR . $method; if ($this->dataSource->hasMethod($name)) { return $this->dataSource->__call($name, $arguments); } if ($this->dataSource->hasMethod($method)) { return $this->dataSource->__call($method, $arguments); } } parent::__call($method, $arguments); }
/** * Pass through any missed method calls to DOMDocument (if they exist) * so that HTMLValue can be treated mostly like an instance of DOMDocument */ public function __call($method, $arguments) { $doc = $this->getDocument(); if (method_exists($doc, $method)) { return call_user_func_array(array($doc, $method), $arguments); } else { return parent::__call($method, $arguments); } }