protected function getProjectCommand(CommandHookInterface $command_hook)
    {
        $method = $command_hook->getCommand();
        $project = $this->getProjectInstance();

        if (!method_exists($project, $method)) {
            throw new CommandHookRuntimeException(
                sprintf("The %s method doesn't exist on the project.", $method)
            );
        }
        $args = array_merge(
            $command_hook->getOptions(),
            $command_hook->getArguments()
        );

        return call_user_func_array([$project, $method], [$args]);
    }
protected function getProjectCommand(CommandHookInterface $command_hook)
    {
        $method = $command_hook->getCommand();
        $project = $this->getProjectInstance();

        if (!method_exists($project, $method)) {
            throw new CommandHookRuntimeException(
                sprintf("The %s method doesn't exist on the project.", $method)
            );
        }
        $args = array_merge(
            $command_hook->getOptions(),
            $command_hook->getArguments()
        );

        return call_user_func_array([$project, $method], [$args]);
    }
protected function getProjectCommand ( CommandHookInterface $ command_hook ) { $ method = $ command_hook -> getCommand ( ) ; $ project = $ this -> getProjectInstance ( ) ; if ( ! method_exists ( $ project , $ method ) ) { throw new CommandHookRuntimeException ( sprintf ( "The %s method doesn't exist on the project." , $ method ) ) ; } $ args = array_merge ( $ command_hook -> getOptions ( ) , $ command_hook -> getArguments ( ) ) ; return call_user_func_array ( [ $ project , $ method ] , [ $ args ] ) ; }
Get project command.

@param CommandHookInterface $command_hook

@return CommandBuilder
Get project command .