|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ning.http.client.providers.jdk.JDKAsyncHttpProvider
public class JDKAsyncHttpProvider
| Constructor Summary | |
|---|---|
JDKAsyncHttpProvider(AsyncHttpClientConfig config)
|
|
| Method Summary | ||
|---|---|---|
void |
close()
Close the current underlying TCP/HTTP connection.s |
|
|
execute(Request request,
AsyncHandler<T> handler)
Execute the request and invoke the AsyncHandler when the response arrive. |
|
Response |
prepareResponse(HttpResponseStatus status,
HttpResponseHeaders headers,
java.util.Collection<HttpResponseBodyPart> bodyParts)
Prepare a Response |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JDKAsyncHttpProvider(AsyncHttpClientConfig config)
| Method Detail |
|---|
public <T> java.util.concurrent.Future<T> execute(Request request,
AsyncHandler<T> handler)
throws java.io.IOException
AsyncHttpProviderAsyncHandler when the response arrive.
execute in interface AsyncHttpProvider<java.net.HttpURLConnection>handler - an instance of AsyncHandler
Future of Type T.
java.io.IOExceptionpublic void close()
AsyncHttpProvider
close in interface AsyncHttpProvider<java.net.HttpURLConnection>
public Response prepareResponse(HttpResponseStatus status,
HttpResponseHeaders headers,
java.util.Collection<HttpResponseBodyPart> bodyParts)
AsyncHttpProviderResponse
prepareResponse in interface AsyncHttpProvider<java.net.HttpURLConnection>status - HttpResponseStatusheaders - HttpResponseHeadersbodyParts - list of HttpResponseBodyPart
Response
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||