public class Response
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private boolean |
consumed |
private org.apache.http.HttpResponse |
response |
| Constructor and Description |
|---|
Response(org.apache.http.HttpResponse response) |
| Modifier and Type | Method and Description |
|---|---|
private void |
assertNotConsumed() |
void |
discardContent()
Discards response content and deallocates all resources associated with it.
|
private void |
dispose() |
<T> T |
handleResponse(ResponseHandler<T> handler)
Handles the response using the specified
ResponseHandler |
Content |
returnContent() |
org.apache.http.HttpResponse |
returnResponse() |
void |
saveContent(java.io.File file) |
private final org.apache.http.HttpResponse response
private boolean consumed
private void assertNotConsumed()
private void dispose()
public void discardContent()
public <T> T handleResponse(ResponseHandler<T> handler) throws ClientProtocolException, java.io.IOException
ResponseHandlerClientProtocolExceptionjava.io.IOExceptionpublic Content returnContent() throws ClientProtocolException, java.io.IOException
ClientProtocolExceptionjava.io.IOExceptionpublic org.apache.http.HttpResponse returnResponse()
throws java.io.IOException
java.io.IOExceptionpublic void saveContent(java.io.File file)
throws java.io.IOException
java.io.IOException