Package | Description |
---|---|
org.springframework.http.client |
Contains an abstraction over client-side HTTP.
|
org.springframework.http.client.support |
This package provides generic HTTP support classes,
to be used by higher-level classes like RestTemplate.
|
org.springframework.mock.http.client |
Mock implementations of client-side HTTP abstractions.
|
org.springframework.test.web.client |
Contains client-side REST testing support.
|
org.springframework.test.web.client.response |
Contains built-in
ResponseCreator
implementations. |
org.springframework.web.client |
Core package of the client-side web support.
|
Modifier and Type | Class and Description |
---|---|
class |
AbstractClientHttpRequest
Abstract base for
ClientHttpRequest that makes sure that headers
and body are not written multiple times. |
Modifier and Type | Method and Description |
---|---|
ClientHttpRequest |
SimpleClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod) |
ClientHttpRequest |
HttpComponentsClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod) |
ClientHttpRequest |
AbstractClientHttpRequestFactoryWrapper.createRequest(URI uri,
HttpMethod httpMethod)
This implementation simply calls
AbstractClientHttpRequestFactoryWrapper.createRequest(URI, HttpMethod, ClientHttpRequestFactory)
with the wrapped request factory provided to the
constructor. |
ClientHttpRequest |
OkHttp3ClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod) |
ClientHttpRequest |
ClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod)
Create a new
ClientHttpRequest for the specified URI and HTTP method. |
ClientHttpRequest |
Netty4ClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod)
Deprecated.
|
protected abstract ClientHttpRequest |
AbstractClientHttpRequestFactoryWrapper.createRequest(URI uri,
HttpMethod httpMethod,
ClientHttpRequestFactory requestFactory)
Create a new
ClientHttpRequest for the specified URI and HTTP method
by using the passed-on request factory. |
protected ClientHttpRequest |
BufferingClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod,
ClientHttpRequestFactory requestFactory) |
protected ClientHttpRequest |
InterceptingClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod,
ClientHttpRequestFactory requestFactory) |
Modifier and Type | Method and Description |
---|---|
void |
ClientHttpRequestInitializer.initialize(ClientHttpRequest request)
Initialize the given client HTTP request.
|
Modifier and Type | Method and Description |
---|---|
protected ClientHttpRequest |
HttpAccessor.createRequest(URI url,
HttpMethod method)
Create a new
ClientHttpRequest via this template's ClientHttpRequestFactory . |
Modifier and Type | Class and Description |
---|---|
class |
MockAsyncClientHttpRequest
Deprecated.
as of Spring 5.0, with no direct replacement
|
class |
MockClientHttpRequest
Mock implementation of
ClientHttpRequest . |
Modifier and Type | Method and Description |
---|---|
ClientHttpRequest |
MockMvcClientHttpRequestFactory.createRequest(URI uri,
HttpMethod httpMethod) |
Modifier and Type | Method and Description |
---|---|
protected List<ClientHttpRequest> |
AbstractRequestExpectationManager.getRequests()
Return a read-only list of requests executed so far.
|
Modifier and Type | Method and Description |
---|---|
ClientHttpResponse |
DefaultRequestExpectation.createResponse(ClientHttpRequest request)
Note that as of 5.0.3, the creation of the response, which may block
intentionally, is separated from request count tracking, and this
method no longer increments the count transparently.
|
ClientHttpResponse |
ResponseCreator.createResponse(ClientHttpRequest request)
Create a response for the given request.
|
protected AssertionError |
AbstractRequestExpectationManager.createUnexpectedRequestError(ClientHttpRequest request)
Return an
AssertionError that a sub-class can raise for an
unexpected request. |
RequestExpectation |
AbstractRequestExpectationManager.RequestExpectationGroup.findExpectation(ClientHttpRequest request)
Return a matching expectation, or
null if none match. |
void |
DefaultRequestExpectation.match(ClientHttpRequest request) |
void |
RequestMatcher.match(ClientHttpRequest request)
Match the given request against specific expectations.
|
RequestExpectation |
UnorderedRequestExpectationManager.matchRequest(ClientHttpRequest request) |
protected RequestExpectation |
AbstractRequestExpectationManager.matchRequest(ClientHttpRequest request)
As of 5.0.3 subclasses should implement this method instead of
AbstractRequestExpectationManager.validateRequestInternal(ClientHttpRequest) in order to match the
request to an expectation, leaving the call to create the response as a separate step
(to be invoked by this class). |
protected RequestExpectation |
SimpleRequestExpectationManager.matchRequest(ClientHttpRequest request) |
ClientHttpResponse |
RequestExpectationManager.validateRequest(ClientHttpRequest request)
Validate the given actual request against the declared expectations.
|
ClientHttpResponse |
AbstractRequestExpectationManager.validateRequest(ClientHttpRequest request) |
protected ClientHttpResponse |
AbstractRequestExpectationManager.validateRequestInternal(ClientHttpRequest request)
Deprecated.
as of 5.0.3, subclasses should implement
AbstractRequestExpectationManager.matchRequest(ClientHttpRequest)
instead and return only the matched expectation, leaving the call to create the response
as a separate step (to be invoked by this class). |
Modifier and Type | Method and Description |
---|---|
ClientHttpResponse |
DefaultResponseCreator.createResponse(ClientHttpRequest request) |
Modifier and Type | Method and Description |
---|---|
void |
RequestCallback.doWithRequest(ClientHttpRequest request)
|