|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.android.volley.toolbox.HttpClientStack
public class HttpClientStack
An HttpStack that performs request over an HttpClient
.
Field Summary | |
---|---|
protected HttpClient |
mClient
|
Constructor Summary | |
---|---|
HttpClientStack(HttpClient client)
|
Method Summary | |
---|---|
(package private) static HttpUriRequest |
createHttpRequest(Request<?> request,
Map<String,String> additionalHeaders)
Creates the appropriate subclass of HttpUriRequest for passed in request. |
protected void |
onPrepareRequest(HttpUriRequest request)
Called before the request is executed using the underlying HttpClient. |
HttpResponse |
performRequest(Request<?> request,
Map<String,String> additionalHeaders)
Performs an HTTP request with the given parameters. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final HttpClient mClient
Constructor Detail |
---|
public HttpClientStack(HttpClient client)
Method Detail |
---|
public HttpResponse performRequest(Request<?> request, Map<String,String> additionalHeaders) throws 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()
IOException
AuthFailureError
static HttpUriRequest createHttpRequest(Request<?> request, Map<String,String> additionalHeaders) throws AuthFailureError
AuthFailureError
protected void onPrepareRequest(HttpUriRequest request) throws IOException
Overwrite in subclasses to augment the request.
IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |