src/Router.php
public function handleArgv(array $argv = null)
    {
        if ($argv === null) {
            $argv = isset($_SERVER['argv']) ? $_SERVER['argv'] : array();
        }
        array_shift($argv);

        return $this->handleArgs($argv);
    }
public function handleArgv(array $argv = null)
    {
        if ($argv === null) {
            $argv = isset($_SERVER['argv']) ? $_SERVER['argv'] : array();
        }
        array_shift($argv);

        return $this->handleArgs($argv);
    }
public function handleArgv ( array $ argv = null ) { if ( $ argv === null ) { $ argv = isset ( $ _SERVER [ 'argv' ] ) ? $ _SERVER [ 'argv' ] : array ( ) ; } array_shift ( $ argv ) ; return $ this -> handleArgs ( $ argv ) ; }
Executes by matching the `argv` against all registered routes and then returns

Unlike `execArgv()` this method will try to execute the route callback
and then return whatever the route callback returned.

If no route could be found or if the route callback throws an Exception,
it will throw an Exception.

You can explicitly pass in your `argv` or it will automatically use the
values from the $_SERVER superglobal. The `argv` is an array that will
always start with the calling program as the first element. We simply
ignore this first element and then process the remaining elements
according to the registered routes.

@param array|null $argv
@return mixed will be the return value from the matched route callback
@throws Exception if the executed route callback throws an exception
@throws NoRouteFoundException If no matching route could be found
@uses self::handleArgs()
Executes by matching the argv against all registered routes and then returns