|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface HttpClient
Interface for an HTTP client. HTTP clients encapsulate a smorgasbord of objects required to execute HTTP requests while handling cookies, authentication, connection management, and other features. Thread safety of HTTP clients depends on the implementation and configuration of the specific client.
| Method Summary | ||
|---|---|---|
HttpResponse |
execute(HttpHost target,
HttpRequest request)
Executes a request to the target using the default context. |
|
HttpResponse |
execute(HttpHost target,
HttpRequest request,
HttpContext context)
Executes a request to the target using the given context. |
|
|
execute(HttpHost target,
HttpRequest request,
ResponseHandler<? extends T> responseHandler)
Executes a request to the target using the default context and processes the response using the given response handler. |
|
|
execute(HttpHost target,
HttpRequest request,
ResponseHandler<? extends T> responseHandler,
HttpContext context)
Executes a request to the target using the given context and processes the response using the given response handler. |
|
HttpResponse |
execute(HttpUriRequest request)
Executes a request using the default context. |
|
HttpResponse |
execute(HttpUriRequest request,
HttpContext context)
Executes a request using the given context. |
|
|
execute(HttpUriRequest request,
ResponseHandler<? extends T> responseHandler)
Executes a request using the default context and processes the response using the given response handler. |
|
|
execute(HttpUriRequest request,
ResponseHandler<? extends T> responseHandler,
HttpContext context)
Executes a request using the given context and processes the response using the given response handler. |
|
ClientConnectionManager |
getConnectionManager()
Obtains the connection manager used by this client. |
|
HttpParams |
getParams()
Obtains the parameters for this client. |
|
| Method Detail |
|---|
HttpParams getParams()
ClientConnectionManager getConnectionManager()
HttpResponse execute(HttpUriRequest request)
throws IOException,
ClientProtocolException
request - the request to execute
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
HttpResponse execute(HttpUriRequest request,
HttpContext context)
throws IOException,
ClientProtocolException
request - the request to executecontext - the context to use for the execution, or
null to use the default context
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
HttpResponse execute(HttpHost target,
HttpRequest request)
throws IOException,
ClientProtocolException
target - the target host for the request.
Implementations may accept null
if they can still determine a route, for example
to a default target or by inspecting the request.request - the request to execute
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
HttpResponse execute(HttpHost target,
HttpRequest request,
HttpContext context)
throws IOException,
ClientProtocolException
target - the target host for the request.
Implementations may accept null
if they can still determine a route, for example
to a default target or by inspecting the request.request - the request to executecontext - the context to use for the execution, or
null to use the default context
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
<T> T execute(HttpUriRequest request,
ResponseHandler<? extends T> responseHandler)
throws IOException,
ClientProtocolException
request - the request to executeresponseHandler - the response handler
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
<T> T execute(HttpUriRequest request,
ResponseHandler<? extends T> responseHandler,
HttpContext context)
throws IOException,
ClientProtocolException
request - the request to executeresponseHandler - the response handler
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
<T> T execute(HttpHost target,
HttpRequest request,
ResponseHandler<? extends T> responseHandler)
throws IOException,
ClientProtocolException
target - the target host for the request.
Implementations may accept null
if they can still determine a route, for example
to a default target or by inspecting the request.request - the request to executeresponseHandler - the response handler
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
<T> T execute(HttpHost target,
HttpRequest request,
ResponseHandler<? extends T> responseHandler,
HttpContext context)
throws IOException,
ClientProtocolException
target - the target host for the request.
Implementations may accept null
if they can still determine a route, for example
to a default target or by inspecting the request.request - the request to executeresponseHandler - the response handlercontext - the context to use for the execution, or
null to use the default context
IOException - in case of a problem or the connection was aborted
ClientProtocolException - in case of an http protocol error
|
Build 1.0_r1(from source) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||