Controller
class Controller
A wrapper for a controller, mapped to a route.
__call() forwards method-calls to Route, but returns instance of Controller listing Route's methods below, so that IDEs know they are valid
Methods
string
getRouteName()
Gets the controller's route name.
bind(string $routeName)
Sets the controller's route.
__call($method, $arguments)
No description
freeze()
Freezes the controller.
generateRouteName($prefix)
No description
Controller
assert(string $variable, string $regexp)
No description
Controller
value(string $variable, mixed $default)
No description
Controller
convert(string $variable, mixed $callback)
No description
Controller
method(string $method)
No description
Controller
requireHttp()
No description
Controller
requireHttps()
No description
Controller
before(mixed $callback)
No description
Controller
after(mixed $callback)
No description
Controller
when(string $condition)
No description
Details
at line 45
__construct(Route $route)
Constructor.
at line 55
Route
getRoute()
Gets the controller's route.
at line 65
string
getRouteName()
Gets the controller's route name.
at line 77
Controller
bind(string $routeName)
Sets the controller's route.
at line 88
__call($method, $arguments)
at line 104
freeze()
Freezes the controller.
Once the controller is frozen, you can no longer change the route name