Package org.forgerock.openig.openam
Class RequestResourceUriProvider
java.lang.Object
org.forgerock.openig.openam.RequestResourceUriProvider
- All Implemented Interfaces:
ResourceUriProvider
The
RequestResourceUriProvider has the following configuration:
{
"type": "RequestResourceUriProvider",
"config": {
"useOriginalUri" : boolean [OPTIONAL - default to false. When true, the original URI rather than
the request URI will be used to create the resourceUri.]
"includeQueryParams" : boolean [OPTIONAL - default to true. When false, any query parameters
in the URI will be excluded from the resourceUri.]
}
}
Returns the URI to be used as the resource for the policy request based on either the request URI
or the original URI.- Since:
- 7.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classCreates and initializes a RequestResourceUriProvider in a heap environment. -
Constructor Summary
ConstructorsConstructorDescriptionCreate a newRequestResourceUriProviderbased on the defaults.RequestResourceUriProvider(boolean useOriginalUri, boolean includeQueryParams) Create a newRequestResourceUriProviderbased on the passed parameters. -
Method Summary
Modifier and TypeMethodDescriptionresourceUri(Context context, Request request) Returns the resource URI as aStringto be used when making policy requests.
-
Constructor Details
-
RequestResourceUriProvider
public RequestResourceUriProvider()Create a newRequestResourceUriProviderbased on the defaults. -
RequestResourceUriProvider
public RequestResourceUriProvider(boolean useOriginalUri, boolean includeQueryParams) Create a newRequestResourceUriProviderbased on the passed parameters.- Parameters:
useOriginalUri- Set totrueto make use of the original URI when creating the resourceUri.includeQueryParams- Set tofalseto exclude any query parameters in the resourceUri.
-
-
Method Details
-
resourceUri
Description copied from interface:ResourceUriProviderReturns the resource URI as aStringto be used when making policy requests.- Specified by:
resourceUriin interfaceResourceUriProvider- Parameters:
context- The request context.request- The request.- Returns:
- a
Stringrepresenting the resource URI.
-