RestClient.Builder .
| Modifier and Type | Field and Description |
|---|---|
| private String | |
| private HttpHeaders | |
| private Consumer | |
| private Map | |
| private static final boolean | |
| private static final boolean | |
| private List | |
| private List | |
| private static final boolean | |
| private static final boolean | |
| private static final boolean | |
| private static final boolean | |
| private static final boolean | |
| private static final boolean | |
| private static final boolean | |
| private List | |
| private ClientRequestObservationConvention | |
| private ObservationRegistry | |
| private ClientHttpRequestFactory | |
| private List | |
| private UriBuilderFactory |
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public |
| baseUrl | back to summary |
|---|---|
| private String baseUrl
| |
| defaultHeaders | back to summary |
|---|---|
| private HttpHeaders defaultHeaders
| |
| defaultRequest | back to summary |
|---|---|
| private Consumer<RestClient. | |
| defaultUriVariables | back to summary |
|---|---|
| private Map<String, ?> defaultUriVariables
| |
| gsonPresent | back to summary |
|---|---|
| private static final boolean gsonPresent | |
| httpComponentsClientPresent | back to summary |
|---|---|
| private static final boolean httpComponentsClientPresent | |
| initializers | back to summary |
|---|---|
| private List<ClientHttpRequestInitializer> initializers
| |
| interceptors | back to summary |
|---|---|
| private List<ClientHttpRequestInterceptor> interceptors
| |
| jackson2CborPresent | back to summary |
|---|---|
| private static final boolean jackson2CborPresent | |
| jackson2Present | back to summary |
|---|---|
| private static final boolean jackson2Present | |
| jackson2SmilePresent | back to summary |
|---|---|
| private static final boolean jackson2SmilePresent | |
| jdkClientPresent | back to summary |
|---|---|
| private static final boolean jdkClientPresent | |
| jettyClientPresent | back to summary |
|---|---|
| private static final boolean jettyClientPresent | |
| jsonbPresent | back to summary |
|---|---|
| private static final boolean jsonbPresent | |
| kotlinSerializationJsonPresent | back to summary |
|---|---|
| private static final boolean kotlinSerializationJsonPresent | |
| messageConverters | back to summary |
|---|---|
| private List<HttpMessageConverter<?>> messageConverters
| |
| observationConvention | back to summary |
|---|---|
| private ClientRequestObservationConvention observationConvention
| |
| observationRegistry | back to summary |
|---|---|
| private ObservationRegistry observationRegistry | |
| requestFactory | back to summary |
|---|---|
| private ClientHttpRequestFactory requestFactory
| |
| statusHandlers | back to summary |
|---|---|
| private List<StatusHandler> statusHandlers
| |
| uriBuilderFactory | back to summary |
|---|---|
| private UriBuilderFactory uriBuilderFactory
| |
| DefaultRestClientBuilder | back to summary |
|---|---|
| public DefaultRestClientBuilder() | |
| DefaultRestClientBuilder | back to summary |
|---|---|
| public DefaultRestClientBuilder(DefaultRestClientBuilder other) | |
| DefaultRestClientBuilder | back to summary |
|---|---|
| public DefaultRestClientBuilder(RestTemplate restTemplate) | |
| apply | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Apply the given This can be useful for applying pre-packaged customizations.
| |
| baseUrl | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure a base URL for requests. Effectively a shortcut for: String baseUrl = "https://abc.go.com/v1"; DefaultUriBuilderFactory factory = new DefaultUriBuilderFactory(baseUrl); RestClient client = RestClient.builder().uriBuilderFactory(factory).build(); The Note this method is mutually exclusive with
| |
| build | back to summary |
|---|---|
| public RestClient build() Implements org. Doc from org. Build the
| |
| clone | back to summary |
|---|---|
| public RestClient. Overrides java. Implements org. Doc from org. Clone this
| |
| copyDefaultHeaders | back to summary |
|---|---|
private HttpHeaders copyDefaultHeaders()
| |
| defaultHeader | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Global option to specify a header to be added to every request, if the request does not already contain such a header.
| |
| defaultHeaders | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Provide a consumer to access to every default header declared so far, with the possibility to add, replace, or remove.
| |
| defaultRequest | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Provide a consumer to customize every request being built.
| |
| defaultStatusHandler | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Register a default status handler to apply to every response. Such default handlers are applied in the order in which they are registered, and after any others that are registered for a specific response.
| |
| defaultStatusHandler | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Register a default status handler to apply to every response. Such default handlers are applied in the order in which they are registered, and after any others that are registered for a specific response.
| |
| defaultStatusHandlerInternal | back to summary |
|---|---|
| private RestClient. | |
| defaultUriVariables | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure default URL variable values to use when expanding URI
templates with a Map<String, ?> defaultVars = ...; DefaultUriBuilderFactory factory = new DefaultUriBuilderFactory(); factory.setDefaultVariables(defaultVars); RestClient client = RestClient.builder().uriBuilderFactory(factory).build(); Note this method is mutually exclusive with
| |
| getRequestFactory | back to summary |
|---|---|
| private static ClientHttpRequestFactory getRequestFactory(RestTemplate restTemplate) | |
| getUriBuilderFactory | back to summary |
|---|---|
private static UriBuilderFactory getUriBuilderFactory(RestTemplate restTemplate)
| |
| hasRestTemplateDefaults | back to summary |
|---|---|
| private static boolean hasRestTemplateDefaults(DefaultUriBuilderFactory factory) Indicate whether this | |
| initHeaders | back to summary |
|---|---|
| private HttpHeaders initHeaders() | |
| initInitializers | back to summary |
|---|---|
| private List | |
| initInterceptors | back to summary |
|---|---|
| private List | |
| initMessageConverters | back to summary |
|---|---|
| private List | |
| initRequestFactory | back to summary |
|---|---|
| private ClientHttpRequestFactory initRequestFactory() | |
| initUriBuilderFactory | back to summary |
|---|---|
| private UriBuilderFactory initUriBuilderFactory() | |
| messageConverters | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure the message converters for the
| |
| observationConvention | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure the
| |
| observationRegistry | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure the
| |
| requestFactory | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Configure the If no request factory is specified,
| |
| requestInitializer | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Add the given request initializer to the end of the initializer chain.
| |
| requestInitializers | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Manipulate the initializers with the given consumer. The list provided to the consumer is "live", so that the consumer can be used to remove initializers, change ordering, etc.
| |
| requestInterceptor | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Add the given request interceptor to the end of the interceptor chain.
| |
| requestInterceptors | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Manipulate the interceptors with the given consumer. The list provided to the consumer is "live", so that the consumer can be used to remove interceptors, change ordering, etc.
| |
| uriBuilderFactory | back to summary |
|---|---|
| public RestClient. Implements org. Doc from org. Provide a pre-configured
| |