private function invokeAction($object, $method, array $arguments)
    {
        $methodInfo = $this->reflectionFactory->getMethod(
            get_class($object), $method
        );
        $parameters = $methodInfo->getParameters();
        $values = array();
        $total = count($parameters);
        for ($i = 0; $i < $total; $i++) {
            $parameter = array_shift($parameters);
            $name = $parameter->getName();
            if (isset($arguments[$name])) {
                $values[] = $arguments[$name];
            } else if ($parameter->isOptional()) {
                $values[] = $parameter->getDefaultValue();
            } else {
                $ctl = get_class($object);
                throw new MvcException(
                	"Missing required argument: $name for action $ctl:$method"
                );
            }
        }
        return $methodInfo->invokeArgs($object, $values);
    }
private function invokeAction($object, $method, array $arguments)
    {
        $methodInfo = $this->reflectionFactory->getMethod(
            get_class($object), $method
        );
        $parameters = $methodInfo->getParameters();
        $values = array();
        $total = count($parameters);
        for ($i = 0; $i < $total; $i++) {
            $parameter = array_shift($parameters);
            $name = $parameter->getName();
            if (isset($arguments[$name])) {
                $values[] = $arguments[$name];
            } else if ($parameter->isOptional()) {
                $values[] = $parameter->getDefaultValue();
            } else {
                $ctl = get_class($object);
                throw new MvcException(
                	"Missing required argument: $name for action $ctl:$method"
                );
            }
        }
        return $methodInfo->invokeArgs($object, $values);
    }
private function invokeAction ( $ object , $ method , array $ arguments ) { $ methodInfo = $ this -> reflectionFactory -> getMethod ( get_class ( $ object ) , $ method ) ; $ parameters = $ methodInfo -> getParameters ( ) ; $ values = array ( ) ; $ total = count ( $ parameters ) ; for ( $ i = 0 ; $ i < $ total ; $ i ++ ) { $ parameter = array_shift ( $ parameters ) ; $ name = $ parameter -> getName ( ) ; if ( isset ( $ arguments [ $ name ] ) ) { $ values [ ] = $ arguments [ $ name ] ; } else if ( $ parameter -> isOptional ( ) ) { $ values [ ] = $ parameter -> getDefaultValue ( ) ; } else { $ ctl = get_class ( $ object ) ; throw new MvcException ( "Missing required argument: $name for action $ctl:$method" ) ; } } return $ methodInfo -> invokeArgs ( $ object , $ values ) ; }
Calls the specified method from the specifed object using the specified
arguments map.

@param object $object
@param string $method Method name
@param array $arguments Map of arguments, where key is argument name,
and value is argument value.

@return mxied
Calls the specified method from the specifed object using the specified arguments map .