private function call($command)
    {
        if (!in_array($command, static::COMMAND)) {
            $this->throwFailsCommand("The command '$command' not exists.", 'help');
        }

        if (!$this->arg->getParameter('action')) {
            if ($this->arg->getParameter('target') == 'help') {
                $this->help($command);

                exit(0);
            }
        }

        try {
            call_user_func_array(
                [$this, $command],
                [$this->arg->getParameter('target')]
            );
        } catch (\Exception $e) {
            echo $e->getMessage();

            exit(1);
        }
    }
private function call($command)
    {
        if (!in_array($command, static::COMMAND)) {
            $this->throwFailsCommand("The command '$command' not exists.", 'help');
        }

        if (!$this->arg->getParameter('action')) {
            if ($this->arg->getParameter('target') == 'help') {
                $this->help($command);

                exit(0);
            }
        }

        try {
            call_user_func_array(
                [$this, $command],
                [$this->arg->getParameter('target')]
            );
        } catch (\Exception $e) {
            echo $e->getMessage();

            exit(1);
        }
    }
private function call ( $ command ) { if ( ! in_array ( $ command , static :: COMMAND ) ) { $ this -> throwFailsCommand ( "The command '$command' not exists." , 'help' ) ; } if ( ! $ this -> arg -> getParameter ( 'action' ) ) { if ( $ this -> arg -> getParameter ( 'target' ) == 'help' ) { $ this -> help ( $ command ) ; exit ( 0 ) ; } } try { call_user_func_array ( [ $ this , $ command ] , [ $ this -> arg -> getParameter ( 'target' ) ] ) ; } catch ( \ Exception $ e ) { echo $ e -> getMessage ( ) ; exit ( 1 ) ; } }
Calls a command

@param  string $command

@return void
@throws
Calls a command