Top Description Fields Constructors Methods
org.springframework.http.client

pack-priv final Class BufferingClientHttpRequestWrapper

extends AbstractBufferingClientHttpRequest
Class Inheritance
Imports
java.io.IOException, .OutputStream, java.net.URI, org.springframework.http.HttpHeaders, .HttpMethod, .StreamingHttpOutputMessage, org.springframework.util.StreamUtils

Simple implementation of ClientHttpRequest that wraps another request.
Author
Arjen Poutsma
Since
3.1

Field Summary

Modifier and TypeField and Description
private final ClientHttpRequest

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
protected ClientHttpResponse
executeInternal(HttpHeaders
the HTTP headers
headers
,
byte[]
the body content
bufferedOutput
)

Implements abstract org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal.

Abstract template method that writes the given headers and content to the HTTP request.

public HttpMethod
getMethod()

Implements org.springframework.http.HttpRequest.getMethod.

Return the HTTP method of the request.

public URI
getURI()

Implements org.springframework.http.HttpRequest.getURI.

Return the URI of the request (including a query string if any, but only if it is well-formed for a URI representation).

Inherited from org.springframework.http.client.AbstractBufferingClientHttpRequest:
executeInternalgetBodyInternal

Field Detail

requestback to summary
private final ClientHttpRequest request

Constructor Detail

BufferingClientHttpRequestWrapperback to summary
pack-priv BufferingClientHttpRequestWrapper(ClientHttpRequest request)

Method Detail

executeInternalback to summary
protected ClientHttpResponse executeInternal(HttpHeaders headers, byte[] bufferedOutput) throws IOException

Implements abstract org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal.

Doc from org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal.

Abstract template method that writes the given headers and content to the HTTP request.

Parameters
headers:HttpHeaders

the HTTP headers

bufferedOutput:byte[]

the body content

Returns:ClientHttpResponse

the response object for the executed request

Annotations
@Override
getMethodback to summary
public HttpMethod getMethod()

Implements org.springframework.http.HttpRequest.getMethod.

Doc from org.springframework.http.HttpRequest.getMethod.

Return the HTTP method of the request.

Returns:HttpMethod

the HTTP method as an HttpMethod value

Annotations
@Override
getURIback to summary
public URI getURI()

Implements org.springframework.http.HttpRequest.getURI.

Doc from org.springframework.http.HttpRequest.getURI.

Return the URI of the request (including a query string if any, but only if it is well-formed for a URI representation).

Returns:URI

the URI of the request (never null)

Annotations
@Override