Class UriBuilderFactoryArgumentResolver
java.lang.Object
org.springframework.web.service.invoker.UriBuilderFactoryArgumentResolver
- All Implemented Interfaces:
HttpServiceArgumentResolver
public class UriBuilderFactoryArgumentResolver
extends Object
implements HttpServiceArgumentResolver
An
HttpServiceArgumentResolver
that uses the provided
UriBuilderFactory
to expand the UriTemplate
.
Unlike with the UrlArgumentResolver
,
if the UriBuilderFactoryArgumentResolver
is provided,
it will not override the entire URL
, but just the baseUri
.
This allows for dynamically setting the baseUri
,
while keeping the path
specified through class
and method annotations.
- Since:
- 6.1
- Author:
- Olga Maciaszek-Sharma
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
resolve
(Object argument, MethodParameter parameter, HttpRequestValues.Builder requestValues) Resolve the argument value.
-
Constructor Details
-
UriBuilderFactoryArgumentResolver
public UriBuilderFactoryArgumentResolver()
-
-
Method Details
-
resolve
public boolean resolve(@Nullable Object argument, MethodParameter parameter, HttpRequestValues.Builder requestValues) Description copied from interface:HttpServiceArgumentResolver
Resolve the argument value.- Specified by:
resolve
in interfaceHttpServiceArgumentResolver
- Parameters:
argument
- the argument valueparameter
- the method parameter for the argumentrequestValues
- builder to add HTTP request values to- Returns:
true
if the argument was resolved,false
otherwise
-