public interface HttpClientConnection extends HttpConnection
| Modifier and Type | Method and Description |
|---|---|
void |
flush()
Writes out all pending buffered data over the open connection.
|
boolean |
isResponseAvailable(int timeout)
Checks if response data is available from the connection.
|
void |
receiveResponseEntity(HttpResponse response)
Receives the next response entity available from this connection and
attaches it to an existing HttpResponse object.
|
HttpResponse |
receiveResponseHeader()
Receives the request line and headers of the next response available from
this connection.
|
void |
sendRequestEntity(HttpEntityEnclosingRequest request)
Sends the request entity over the connection.
|
void |
sendRequestHeader(HttpRequest request)
Sends the request line and all headers over the connection.
|
close, getMetrics, getSocketTimeout, isOpen, isStale, setSocketTimeout, shutdownboolean isResponseAvailable(int timeout)
throws IOException
timeout - the maximum time in milliseconds to wait for datatimeout milliseconds.IOException - if an error happens on the connectionvoid sendRequestHeader(HttpRequest request) throws HttpException, IOException
request - the request whose headers to send.HttpException - in case of HTTP protocol violationIOException - in case of an I/O errorvoid sendRequestEntity(HttpEntityEnclosingRequest request) throws HttpException, IOException
request - the request whose entity to send.HttpException - in case of HTTP protocol violationIOException - in case of an I/O errorHttpResponse receiveResponseHeader() throws HttpException, IOException
HttpException - in case of HTTP protocol violationIOException - in case of an I/O errorvoid receiveResponseEntity(HttpResponse response) throws HttpException, IOException
response - the response to attach the entity toHttpException - in case of HTTP protocol violationIOException - in case of an I/O errorvoid flush()
throws IOException
IOException - in case of an I/O errorCopyright © 2005–2013 The Apache Software Foundation. All rights reserved.