final class PushMatchedTemplateRouter extends java.lang.Object implements Router
uri template of matched resource of subResource
to routing context.
Before calling this router the PathMatchingRouter must be called which matches the path
and pushes the matched result into the routing context.Router.Continuation| Modifier and Type | Field and Description |
|---|---|
private UriTemplate |
methodTemplate |
private UriTemplate |
resourceTemplate |
| Constructor and Description |
|---|
PushMatchedTemplateRouter(UriTemplate resourceTemplate)
Create a new instance of the push matched template router.
|
PushMatchedTemplateRouter(UriTemplate resourceTemplate,
UriTemplate methodTemplate)
Create a new instance of the push matched template router.
|
| Modifier and Type | Method and Description |
|---|---|
Router.Continuation |
apply(RequestProcessingContext context)
Performs a request routing task and returns the routed request together with
a
routing continuation. |
private final UriTemplate resourceTemplate
private final UriTemplate methodTemplate
PushMatchedTemplateRouter(UriTemplate resourceTemplate, UriTemplate methodTemplate)
This constructor should be used in case a path matching has been performed on both a resource and method paths (in case of sub-resource methods and locators).
resourceTemplate - resource URI template that should be pushed.methodTemplate - (sub-resource) method or locator URI template that should be pushed.PushMatchedTemplateRouter(UriTemplate resourceTemplate)
This constructor should be used in case a single path matching has been performed (in case of resource methods, only the resource path is matched).
resourceTemplate - resource URI template that should be pushed.public Router.Continuation apply(RequestProcessingContext context)
Routerrouting continuation.