lithium\console\command\Route::all()
Lists all connected routes to the router. This is a convenience
alias for the show()
method.
Example:
li3 route
li3 route all
Will return an output similar to:
Template Params
-------- ------
/ {"controller":"pages","action":"view"}
/pages/{:args} {"controller":"pages","action":"view"}
/{:slug:[\w\-]+} {"controller":"posts","action":"show"}
/{:controller}/{:action}/{:args} {"action":"index"}
Returns
voidSource
public function all($scope = true) {
$routes = Router::get(null, true);
$columns = [['Template', 'Params'], ['--------', '------']];
foreach ($routes As $route) {
$info = $route->export();
$columns[] = [$info['template'], json_encode($info['params'])];
}
$this->columns($columns);
}