$request
$request : \ManaPHP\Http\RequestInterface
$_default_routes : array<mixed,\ManaPHP\Http\Router\RouteInterface>
$_regex_routes : array<mixed,\ManaPHP\Http\Router\RouteInterface>
add(string $pattern, string|array $paths = null, string|array $method = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router on any HTTP method
string | $pattern | |
string|array | $paths | |
string|array | $method |
addGet(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is GET
string | $pattern | |
string|array | $paths |
addPost(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is POST
string | $pattern | |
string|array | $paths |
addPut(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is PUT
string | $pattern | |
string|array | $paths |
addPatch(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is PATCH
string | $pattern | |
string|array | $paths |
addDelete(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is DELETE
string | $pattern | |
string|array | $paths |
addOptions(string $pattern = '{all:.*}', string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Add a route to the router that only match if the HTTP method is OPTIONS
string | $pattern | |
string|array | $paths |
addHead(string $pattern, string|array $paths = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route to the router that only match if the HTTP method is HEAD
string | $pattern | |
string|array | $paths |
addRest(string $pattern, string $controller = null) : \ManaPHP\Http\Router\RouteInterface
string | $pattern | |
string | $controller |
match(string $uri = null, string $method = null) : \ManaPHP\Http\RouterContext|false
Handles routing information received from the rewrite engine
string | $uri | |
string | $method |
_addRoute(string $pattern, string|array $paths = null, string $method = null) : \ManaPHP\Http\Router\RouteInterface
Adds a route applying the common attributes
string | $pattern | |
string|array | $paths | |
string | $method |