-
Nested Class Summary
Nested Classes
| Modifier and Type |
Interface |
Description |
static interface |
Routing.Entry |
A routing entry.
|
static interface |
Routing.Group |
A group of routing entries prefixed by a common path.
|
static interface |
Routing.Service |
Adds to the Routing.
|
static class |
Routing.Type |
The type of route entry.
|
-
Method Summary
| Modifier and Type |
Method |
Description |
Routing |
add(Routing.Service routes) |
Add the routes provided by the Routing Service.
|
Routing |
addAll(Collection<Routing.Service> routes) |
Add all the routes provided by the Routing Services.
|
Routing |
after(Handler handler) |
Add an after filter for all requests.
|
Routing |
after(String path,
Handler handler) |
Add a after filter for the given path.
|
List<Routing.Entry> |
all() |
Return all the registered handlers.
|
Routing |
before(Handler handler) |
Add a before filter for all requests.
|
Routing |
before(String path,
Handler handler) |
Add a before filter for the given path.
|
Routing |
delete(Handler handler) |
Add a DELETE handler for "/".
|
Routing |
delete(String path,
Handler handler) |
Add a DELETE handler.
|
Routing |
get(Handler handler) |
Add a GET handler for "/".
|
Routing |
get(String path,
Handler handler) |
Add a GET handler.
|
Routing |
head(Handler handler) |
Add a HEAD handler for "/".
|
Routing |
head(String path,
Handler handler) |
Add a HEAD handler.
|
Routing |
patch(Handler handler) |
Add a PATCH handler for "/".
|
Routing |
patch(String path,
Handler handler) |
Add a PATCH handler.
|
Routing |
path(String path,
Routing.Group group) |
Add a group of route handlers with a common path prefix.
|
Routing |
post(Handler handler) |
Add a POST handler for "/".
|
Routing |
post(String path,
Handler handler) |
Add a POST handler.
|
Routing |
put(Handler handler) |
Add a PUT handler for "/".
|
Routing |
put(String path,
Handler handler) |
Add a PUT handler.
|
Routing |
trace(Handler handler) |
Add a TRACE handler for "/".
|
Routing |
trace(String path,
Handler handler) |
Add a TRACE handler.
|
Routing |
withRoles(Role... permittedRoles) |
Specify permittedRoles for the last added handler using varargs.
|
Routing |
withRoles(Set<Role> permittedRoles) |
Specify permittedRoles for the last added handler.
|
-
Method Details
-
add
Add the routes provided by the Routing Service.
-
addAll
Add all the routes provided by the Routing Services.
-
withRoles
Specify permittedRoles for the last added handler.
routing
.get("/customers", getHandler).withRoles(readRoles)
.post("/customers", postHandler).withRoles(writeRoles)
...
- Parameters:
permittedRoles - The permitted roles required for the last handler
-
withRoles
Specify permittedRoles for the last added handler using varargs.
routing
.get("/customers", getHandler).withRoles(ADMIN, USER)
.post("/customers", postHandler).withRoles(ADMIN)
...
- Parameters:
permittedRoles - The permitted roles required for the last handler
-
path
Add a group of route handlers with a common path prefix.
-
-
head
Add a HEAD handler for "/".
-
-
get
Add a GET handler for "/".
-
-
post
Add a POST handler for "/".
-
-
put
Add a PUT handler for "/".
-
patch
Add a PATCH handler.
-
patch
Add a PATCH handler for "/".
-
delete
Add a DELETE handler.
-
delete
Add a DELETE handler for "/".
-
trace
Add a TRACE handler.
-
trace
Add a TRACE handler for "/".
-
before
Add a before filter for the given path.
-
before
Add a before filter for all requests.
-
after
Add a after filter for the given path.
-
after
Add an after filter for all requests.
-
all
Return all the registered handlers.