GenericRoute
in package
implements
IRoute
A generic route that can be used to define a route with a custom execution function
Table of Contents
Interfaces
- IRoute
- Interface IRequestAction
Properties
- $accessPermission : string|null
- $exec : mixed
Methods
- __construct() : mixed
- accessPermission() : null|string
- Returns the required permission to execute this action, or null if it is not restricted.
- exec() : mixed
- Executes the action and returns the result.
Properties
$accessPermission
private
string|null
$accessPermission
$exec
private
mixed
$exec
Methods
__construct()
public
__construct(callable $exec[, mixed $accessPermission = null ]) : mixed
Parameters
- $exec : callable
- $accessPermission : mixed = null
accessPermission()
Returns the required permission to execute this action, or null if it is not restricted.
public
accessPermission() : null|string
Return values
null|stringexec()
Executes the action and returns the result.
public
exec(mixed $args) : mixed
Parameters
- $args : mixed