public interface AsyncHttpProvider
NettyAsyncHttpProvider is used.| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close the current underlying TCP/HTTP connection.
|
<T> ListenableFuture<T> |
execute(Request request,
AsyncHandler<T> handler)
Execute the request and invoke the
AsyncHandler when the response arrive. |
Response |
prepareResponse(HttpResponseStatus status,
HttpResponseHeaders headers,
Collection<HttpResponseBodyPart> bodyParts)
Prepare a
Response |
<T> ListenableFuture<T> execute(Request request, AsyncHandler<T> handler) throws IOException
AsyncHandler when the response arrive.handler - an instance of AsyncHandlerListenableFuture of Type T.IOExceptionvoid close()
Response prepareResponse(HttpResponseStatus status, HttpResponseHeaders headers, Collection<HttpResponseBodyPart> bodyParts)
Responsestatus - HttpResponseStatusheaders - HttpResponseHeadersbodyParts - list of HttpResponseBodyPartResponseCopyright © 2015. All rights reserved.