◆ get_path_for_callable()
static core\router\util::get_path_for_callable |
( |
string|array|callable | $callable, |
|
|
array | $params, |
|
|
array | $queryparams ) |
|
static |
Get the URI path for the specified callable.
- Parameters
-
string | array | callable | $callable | the Callable to get the URI for |
array | $params | Any parameters to include in the path |
array | $queryparams | Any parameters to include in the query string |
- Return values
-
◆ get_route_instance_for_method()
static core\router\util::get_route_instance_for_method |
( |
callable|array|string | $callable | ) |
|
|
static |
Get the instance of the route::router::route attribute for the specified callable if one is available.
- Parameters
-
callable | array | string | $callable | |
- Return values
-
null|route | The route if one was found. |
◆ get_route_instance_for_request()
Get the route attribute for the specified request.
- Parameters
-
ServerRequestInterface | $request | |
- Return values
-
◆ get_route_name_for_callable()
static core\router\util::get_route_name_for_callable |
( |
callable|array|string | $callable | ) |
|
|
static |
Get the route name for the specified callable.
- Parameters
-
callable | array | string | $callable | |
- Return values
-
- Exceptions
-
coding_exception | If the callable could not be resolved into an Array format |
◆ redirect_to_callable()
static core\router\util::redirect_to_callable |
( |
callable|array|string | $callable, |
|
|
array | $params = [] ) |
|
static |
Redirect to the route at the callable supplied.
- Parameters
-
callable | array | string | $callable | |
array | $params | Any parameters to include in the path @codeCoverageIgnore |
◆ redirect_with_params()
static core\router\util::redirect_with_params |
( |
string|moodle_url | $path, |
|
|
array | $excludeparams = [] ) |
|
static |
Redirect to the specified URL, carrying all parameters across too.
- Parameters
-
string | moodle_url | $path | |
array | $excludeparams | Any parameters to exclude from the query params @codeCoverageIgnore |
The documentation for this class was generated from the following file:
- lib/classes/router/util.php