|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AhcBinding
Binding from Camel to/from AsyncHttpClient
Method Summary | |
---|---|
void |
onComplete(AhcEndpoint endpoint,
org.apache.camel.Exchange exchange,
String url,
ByteArrayOutputStream os,
int contentLength,
int statusCode,
String statusText)
Callback from the AsyncHttpClient when complete and all the response has been received. |
void |
onHeadersReceived(AhcEndpoint endpoint,
org.apache.camel.Exchange exchange,
com.ning.http.client.HttpResponseHeaders headers)
Callback from the AsyncHttpClient when the HTTP headers was received |
void |
onStatusReceived(AhcEndpoint endpoint,
org.apache.camel.Exchange exchange,
com.ning.http.client.HttpResponseStatus responseStatus)
Callback from the AsyncHttpClient when the HTTP response status was received |
void |
onThrowable(AhcEndpoint endpoint,
org.apache.camel.Exchange exchange,
Throwable t)
Callback from the AsyncHttpClient when an exception occurred sending the request. |
com.ning.http.client.Request |
prepareRequest(AhcEndpoint endpoint,
org.apache.camel.Exchange exchange)
Prepares the AHC Request to be send. |
Method Detail |
---|
com.ning.http.client.Request prepareRequest(AhcEndpoint endpoint, org.apache.camel.Exchange exchange) throws Exception
Request
to be send.
endpoint
- the endpointexchange
- the exchange
AsyncHttpClient
Exception
- is thrown if error occurred preparing the requestvoid onThrowable(AhcEndpoint endpoint, org.apache.camel.Exchange exchange, Throwable t) throws Exception
AsyncHttpClient
when an exception occurred sending the request.
endpoint
- the endpointexchange
- the exchanget
- the thrown exception
Exception
- is thrown if error occurred in the callbackvoid onStatusReceived(AhcEndpoint endpoint, org.apache.camel.Exchange exchange, com.ning.http.client.HttpResponseStatus responseStatus) throws Exception
AsyncHttpClient
when the HTTP response status was received
endpoint
- the endpointexchange
- the exchangeresponseStatus
- the HTTP response status
Exception
- is thrown if error occurred in the callbackvoid onHeadersReceived(AhcEndpoint endpoint, org.apache.camel.Exchange exchange, com.ning.http.client.HttpResponseHeaders headers) throws Exception
AsyncHttpClient
when the HTTP headers was received
endpoint
- the endpointexchange
- the exchangeheaders
- the HTTP headers
Exception
- is thrown if error occurred in the callbackvoid onComplete(AhcEndpoint endpoint, org.apache.camel.Exchange exchange, String url, ByteArrayOutputStream os, int contentLength, int statusCode, String statusText) throws Exception
AsyncHttpClient
when complete and all the response has been received.
endpoint
- the endpointexchange
- the exchangeurl
- the url requestedos
- output stream with the HTTP response bodycontentLength
- length of the response bodystatusCode
- the http response codestatusText
- the http status text
Exception
- is thrown if error occurred in the callback
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |