|
Accela SDK for Android
V3.0
|
Public Member Functions | |
| AsyncHttpClient () | |
| void | setCookieStore (CookieStore cookieStore) |
| void | setThreadPool (ThreadPoolExecutor threadPool) |
| void | setUserAgent (String userAgent) |
| void | setSSLSocketFactory (SSLSocketFactory sslSocketFactory) |
| void | addHeader (String header, String value) |
| void | cancelRequests (Context context, boolean mayInterruptIfRunning) |
| Boolean | isCancelled () |
| void | get (String url, AsyncHttpResponseHandler responseHandler) |
| void | get (String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | get (Context context, String url, AsyncHttpResponseHandler responseHandler) |
| void | get (Context context, String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | get (Context context, String url, Header[] headers, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | post (String url, AsyncHttpResponseHandler responseHandler) |
| void | post (String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | post (Context context, String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | post (Context context, String url, HttpEntity entity, String contentType, AsyncHttpResponseHandler responseHandler) |
| void | post (Context context, String url, Header[] headers, RequestParams params, String contentType, AsyncHttpResponseHandler responseHandler) |
| void | put (String url, AsyncHttpResponseHandler responseHandler) |
| void | put (String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | put (Context context, String url, RequestParams params, AsyncHttpResponseHandler responseHandler) |
| void | put (Context context, String url, HttpEntity entity, String contentType, AsyncHttpResponseHandler responseHandler) |
| void | put (Context context, String url, Header[] headers, HttpEntity entity, String contentType, AsyncHttpResponseHandler responseHandler) |
| void | delete (String url, AsyncHttpResponseHandler responseHandler) |
| void | delete (Context context, String url, AsyncHttpResponseHandler responseHandler) |
| void | delete (Context context, String url, Header[] headers, AsyncHttpResponseHandler responseHandler) |
| Boolean | isLoading () |
| String | assembleUrlWithParams (String url, RequestParams params) |
| Map< String, String > | getHeader () |
| List< NameValuePair > | getHttpResponseHeaders () |
Accela Amobile File: AsyncHttpClient.java
Accela, Inc. Copyright (C): 2012
Description: HTTP Client wrapper object, used to process asynchronous HTTP requests.
Notes:
Revision History@since 1.0
|
inline |
|
inline |
Sets headers that will be added to all requests this client makes (before sending).
| header | The name of the header |
| value | The contents of the header |
|
inline |
Append request parameters to URL.
| url | The URL to send the request to. |
| params | Additional URL parameters which will be appended to the URL. |
|
inline |
Cancels any pending (or potentially active) requests associated with the passed Context.
Note: This will only affect requests which were created with a non-null Android Context. This method is intended to be used in the onDestroy method of your Android activities to destroy all requests which are no longer required.
| context | The Android Context instance associated to the request. |
| mayInterruptIfRunning | Specifies if active requests should be cancelled along with pending requests. |
|
inline |
Perform a HTTP DELETE request.
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP DELETE request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP DELETE request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| headers | Set one-time headers for this request |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP GET request, without any parameters.
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP GET request with parameters.
| url | The URL to send the request to. |
| params | Additional GET parameters to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP GET request without any parameters and track the Android Context which initiated the request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP GET request and track the Android Context which initiated the request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| params | Additional GET parameters to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP GET request and track the Android Context which initiated the request with customized headers
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| headers | Set headers only for this request |
| params | Additional GET parameters to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Get client's header map.
|
inline |
Get response's header list.
|
inline |
Get whether the current HTTP request has been cancelled.
|
inline |
Get loading status of current HTTP client.
|
inline |
Perform a HTTP POST request, without any parameters.
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP POST request with parameters.
| url | The URL to send the request to. |
| params | Additional POST parameters or files to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP POST request and track the Android Context which initiated the request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| params | Additional POST parameters or files to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP POST request and track the Android Context which initiated the request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| entity | A raw HttpEntity to send with the request, for example, use this to send string/json/xml payloads to a server by passing a org.apache.http.entity.StringEntity. |
| contentType | The content type of the payload you are sending, for example application/json if sending a json payload. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP POST request and track the Android Context which initiated the request. Set headers only for this request
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| headers | Set headers only for this request |
| params | Additional POST parameters or files to send with the request. |
| contentType | The content type of the payload you are sending, for example application/json if sending a json payload. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP PUT request, without any parameters.
| url | The URL to send the request to. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP PUT request with parameters.
| url | The URL to send the request to. |
| params | Additional PUT parameters or files to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP PUT request and track the Android Context which initiated the request.
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| params | Additional PUT parameters or files to send with the request. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP PUT request and track the Android Context which initiated the request. And set one-time headers for the request
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| entity | A raw HttpEntity to send with the request, for example, use this to send string/json/xml payloads to a server by passing a org.apache.http.entity.StringEntity. |
| contentType | The content type of the payload you are sending, for example application/json if sending a json payload. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Perform a HTTP PUT request and track the Android Context which initiated the request. And set one-time headers for the request
| context | The Android Context which initiated the request. |
| url | The URL to send the request to. |
| headers | Set one-time headers for this request |
| entity | A raw HttpEntity to send with the request, for example, use this to send string/json/xml payloads to a server by passing a org.apache.http.entity.StringEntity. |
| contentType | The content type of the payload you are sending, for example application/json if sending a json payload. |
| responseHandler | The response handler instance that should handle the response. |
|
inline |
Sets an optional CookieStore to use when making requests
| cookieStore | The CookieStore implementation to use, usually an instance of PersistentCookieStore |
|
inline |
Sets the SSLSocketFactory to user when making requests. By default, a new, default SSLSocketFactory is used.
| sslSocketFactory | The socket factory to use for https requests. |
|
inline |
Overrides the threadpool implementation used when queuing/pooling requests. By default, Executors.newCachedThreadPool() is used.
| threadPool | An instance of ThreadPoolExecutor to use for queuing/pooling requests. |
|
inline |
Sets the User-Agent header to be sent with each request.
| userAgent | The string to use in the User-Agent header. |