Phergie_Plugin_Abstract::__call PHP Метод

__call() публичный Метод

Provides do* methods with signatures identical to those of Phergie_Driver_Abstract but that queue up events to be dispatched later.
public __call ( string $name, array $args ) : mixed
$name string Name of the method called
$args array Arguments passed in the call
Результат mixed
    public function __call($name, array $args)
    {
        $subcmd = substr($name, 0, 2);
        if ($subcmd == 'do') {
            $type = strtolower(substr($name, 2));
            $this->getEventHandler()->addEvent($this, $type, $args);
        } else {
            if ($subcmd != 'on') {
                throw new Phergie_Plugin_Exception('Called invalid method ' . $name . ' in ' . get_class($this), Phergie_Plugin_Exception::ERR_INVALID_CALL);
            }
        }
    }