Package org.forgerock.services.routing
Class DelegatingRouteMatcher<R>
java.lang.Object
org.forgerock.services.routing.RouteMatcher<R>
org.forgerock.services.routing.DelegatingRouteMatcher<R>
- Type Parameters:
R- The type or request being matched.
A route matcher that delegates to a provided route matcher.
-
Constructor Summary
ConstructorsConstructorDescriptionDelegatingRouteMatcher(RouteMatcher<R> delegate) Create a new route matcher, delegating to the provided delegate. -
Method Summary
Modifier and TypeMethodDescriptionbooleanEvaluates the request and determines whether it matches the route.inthashCode()The fragment of an API ID that this matcher provides.toString()Returns aStringrepresentation of the route matcher.<D> DtransformApi(D descriptor, ApiProducer<D> producer) Transform the API Descriptor as appropriate for the parent router's view of the child routes.
-
Constructor Details
-
DelegatingRouteMatcher
Create a new route matcher, delegating to the provided delegate.- Parameters:
delegate- The delegate.
-
-
Method Details
-
evaluate
Description copied from class:RouteMatcherEvaluates the request and determines whether it matches the route.- Specified by:
evaluatein classRouteMatcher<R>- Parameters:
context- The request context.request- The request.- Returns:
- A
RouteMatch, if the request matches the route, ornull, if not.
-
toString
Description copied from class:RouteMatcherReturns aStringrepresentation of the route matcher.- Specified by:
toStringin classRouteMatcher<R>- Returns:
- A string representation of the route matcher.
-
idFragment
Description copied from class:RouteMatcherThe fragment of an API ID that this matcher provides.- Specified by:
idFragmentin classRouteMatcher<R>- Returns:
- A fragment of the API ID.
-
hashCode
public int hashCode()- Specified by:
hashCodein classRouteMatcher<R>
-
equals
- Specified by:
equalsin classRouteMatcher<R>
-
transformApi
Description copied from class:RouteMatcherTransform the API Descriptor as appropriate for the parent router's view of the child routes.- Specified by:
transformApiin classRouteMatcher<R>- Type Parameters:
D- The type of descriptor object.- Parameters:
descriptor- The descriptor to be mutated.producer- The API Descriptor producer.- Returns:
- The new descriptor object.
-