Package org.apache.http.client.fluent
Class Response
- java.lang.Object
-
- org.apache.http.client.fluent.Response
-
public class Response extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Response(org.apache.http.HttpResponse response)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method 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 specifiedResponseHandler
Content
returnContent()
org.apache.http.HttpResponse
returnResponse()
void
saveContent(java.io.File file)
-
-
-
Method Detail
-
assertNotConsumed
private void assertNotConsumed()
-
dispose
private void dispose()
-
discardContent
public void discardContent()
Discards response content and deallocates all resources associated with it.
-
handleResponse
public <T> T handleResponse(ResponseHandler<T> handler) throws ClientProtocolException, java.io.IOException
Handles the response using the specifiedResponseHandler
- Throws:
ClientProtocolException
java.io.IOException
-
returnContent
public Content returnContent() throws ClientProtocolException, java.io.IOException
- Throws:
ClientProtocolException
java.io.IOException
-
returnResponse
public org.apache.http.HttpResponse returnResponse() throws java.io.IOException
- Throws:
java.io.IOException
-
saveContent
public void saveContent(java.io.File file) throws java.io.IOException
- Throws:
java.io.IOException
-
-