org.springframework.http.client
Class AbstractBufferingClientHttpRequest
java.lang.Object
org.springframework.http.client.AbstractClientHttpRequest
org.springframework.http.client.AbstractBufferingClientHttpRequest
- All Implemented Interfaces:
- ClientHttpRequest, HttpMessage, HttpOutputMessage, HttpRequest
public abstract class AbstractBufferingClientHttpRequest
- extends AbstractClientHttpRequest
Abstract base for ClientHttpRequest that buffers output in a byte array before sending it over the wire.
- Since:
- 3.0.6
- Author:
- Arjen Poutsma
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractBufferingClientHttpRequest
public AbstractBufferingClientHttpRequest()
getBodyInternal
protected OutputStream getBodyInternal(HttpHeaders headers)
throws IOException
- Description copied from class:
AbstractClientHttpRequest
- Abstract template method that returns the body.
- Specified by:
getBodyInternal in class AbstractClientHttpRequest
- Parameters:
headers - the HTTP headers
- Returns:
- the body output stream
- Throws:
IOException
executeInternal
protected ClientHttpResponse executeInternal(HttpHeaders headers)
throws IOException
- Description copied from class:
AbstractClientHttpRequest
- Abstract template method that writes the given headers and content to the HTTP request.
- Specified by:
executeInternal in class AbstractClientHttpRequest
- Parameters:
headers - the HTTP headers
- Returns:
- the response object for the executed request
- Throws:
IOException
executeInternal
protected abstract ClientHttpResponse executeInternal(HttpHeaders headers,
byte[] bufferedOutput)
throws IOException
- Abstract template method that writes the given headers and content to the HTTP request.
- Parameters:
headers - the HTTP headersbufferedOutput - the body content
- Returns:
- the response object for the executed request
- Throws:
IOException