public function parseArguments(array $args)
    {
        if (!isset($args['action']) || empty($args['action'])) {
            if (isset($args['version']) ||  isset($args['V'])) {
                $this->action = 'Version';
                $this->arguments = $args;
                return $this->arguments;
            }
            if (isset($args['help']) || isset($args['h'])) {
                $this->action = 'Help';
                $this->arguments = $args;
                return $this->arguments;
            }
            throw new RequestException($this, "No valid action argument specified.");
        }
        $this->action = $args['action'];
        unset($args['action']);
        $this->arguments = $args;
        return $this->arguments;
    }
public function parseArguments(array $args)
    {
        if (!isset($args['action']) || empty($args['action'])) {
            if (isset($args['version']) ||  isset($args['V'])) {
                $this->action = 'Version';
                $this->arguments = $args;
                return $this->arguments;
            }
            if (isset($args['help']) || isset($args['h'])) {
                $this->action = 'Help';
                $this->arguments = $args;
                return $this->arguments;
            }
            throw new RequestException($this, "No valid action argument specified.");
        }
        $this->action = $args['action'];
        unset($args['action']);
        $this->arguments = $args;
        return $this->arguments;
    }
public function parseArguments ( array $ args ) { if ( ! isset ( $ args [ 'action' ] ) || empty ( $ args [ 'action' ] ) ) { if ( isset ( $ args [ 'version' ] ) || isset ( $ args [ 'V' ] ) ) { $ this -> action = 'Version' ; $ this -> arguments = $ args ; return $ this -> arguments ; } if ( isset ( $ args [ 'help' ] ) || isset ( $ args [ 'h' ] ) ) { $ this -> action = 'Help' ; $ this -> arguments = $ args ; return $ this -> arguments ; } throw new RequestException ( $ this , "No valid action argument specified." ) ; } $ this -> action = $ args [ 'action' ] ; unset ( $ args [ 'action' ] ) ; $ this -> arguments = $ args ; return $ this -> arguments ; }
Parse the request arguments into a normalized format.

@param array $args An array of arguments to parse.

@return array The normalized array of parsed arguments.
@throws RequestException If no valid action argument is specified.
Parse the request arguments into a normalized format .