Modifier and Type | Class and Description |
---|---|
static class |
HttpClientStack.HttpPatch
The HttpPatch class does not exist in the Android framework, so this has been defined here.
|
Modifier and Type | Field and Description |
---|---|
protected HttpClient |
mClient |
Constructor and Description |
---|
HttpClientStack(HttpClient client) |
Modifier and Type | Method and Description |
---|---|
protected void |
onPrepareRequest(HttpUriRequest request)
Called before the request is executed using the underlying HttpClient.
|
HttpResponse |
performRequest(Request<?> request,
java.util.Map<java.lang.String,java.lang.String> additionalHeaders)
Performs an HTTP request with the given parameters.
|
public HttpResponse performRequest(Request<?> request, java.util.Map<java.lang.String,java.lang.String> additionalHeaders) throws java.io.IOException, AuthFailureError
HttpStack
A GET request is sent if request.getPostBody() == null. A POST request is sent otherwise, and the Content-Type header is set to request.getPostBodyContentType().
performRequest
in interface HttpStack
request
- the request to performadditionalHeaders
- additional headers to be sent together with
Request.getHeaders()
java.io.IOException
AuthFailureError
protected void onPrepareRequest(HttpUriRequest request) throws java.io.IOException
Overwrite in subclasses to augment the request.
java.io.IOException