public class HttpClientImpl extends Object implements HttpClient
| 限定符和类型 | 字段和说明 |
|---|---|
static String |
CHARSET |
static String |
MAX_PER_ROUTE |
static String |
MAX_TOTAL |
static String |
TIME_TO_LIVE |
static String |
TIME_UNIT |
| 构造器和说明 |
|---|
HttpClientImpl() |
HttpClientImpl(boolean force) |
HttpClientImpl(boolean force,
long timeToLive,
TimeUnit tunit,
int maxTotal,
int maxPerRoute,
Charset charset) |
| 限定符和类型 | 方法和说明 |
|---|---|
HttpResponse |
delete(String url)
Http 'DELETE' request.
|
HttpResponse |
delete(String url,
Map<String,String> params)
Http 'DELETE' request.
|
HttpResponse |
delete(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'DELETE' request.
|
HttpResponse |
execute(RequestMethod requestMethod,
String url) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
Map<String,String> params) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
Map<String,String> headers,
Map<String,String> params) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
Map<String,String> headers,
String json) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
Map<String,String> headers,
String stream,
org.apache.http.entity.ContentType contentType) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
String json) |
HttpResponse |
execute(RequestMethod requestMethod,
String url,
String stream,
org.apache.http.entity.ContentType contentType) |
HttpResponse |
get(String url)
Http 'GET' request.
|
HttpResponse |
get(String url,
Map<String,String> params)
Http 'GET' request.
|
HttpResponse |
get(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'GET' request.
|
HttpResponse |
head(String url)
Http 'HEAD' request.
|
HttpResponse |
head(String url,
Map<String,String> params)
Http 'HEAD' request.
|
HttpResponse |
head(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'HEAD' request.
|
HttpResponse |
options(String url)
Http 'OPTIONS' request.
|
HttpResponse |
options(String url,
Map<String,String> params)
Http 'OPTIONS' request.
|
HttpResponse |
options(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'OPTIONS' request.
|
HttpResponse |
patch(String url)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
Map<String,String> params)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
Map<String,String> headers,
String json)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
Map<String,String> headers,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
String json)
Http 'PATCH' request.
|
HttpResponse |
patch(String url,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'PATCH' request.
|
HttpResponse |
post(String url)
Http 'POST' request.
|
HttpResponse |
post(String url,
Map<String,String> params)
Http 'POST' request.
|
HttpResponse |
post(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'POST' request.
|
HttpResponse |
post(String url,
Map<String,String> headers,
String json)
Http 'POST' request.
|
HttpResponse |
post(String url,
Map<String,String> headers,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'POST' request.
|
HttpResponse |
post(String url,
String json)
Http 'POST' request.
|
HttpResponse |
post(String url,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'POST' request.
|
HttpResponse |
put(String url)
Http 'PUT' request.
|
HttpResponse |
put(String url,
Map<String,String> params)
Http 'PUT' request.
|
HttpResponse |
put(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'PUT' request.
|
HttpResponse |
put(String url,
Map<String,String> headers,
String json)
Http 'PUT' request.
|
HttpResponse |
put(String url,
Map<String,String> headers,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'PUT' request.
|
HttpResponse |
put(String url,
String json)
Http 'PUT' request.
|
HttpResponse |
put(String url,
String stream,
org.apache.http.entity.ContentType contentType)
Http 'PUT' request.
|
HttpResponse |
trace(String url)
Http 'TRACE' request.
|
HttpResponse |
trace(String url,
Map<String,String> params)
Http 'TRACE' request.
|
HttpResponse |
trace(String url,
Map<String,String> headers,
Map<String,String> params)
Http 'TRACE' request.
|
public HttpResponse get(String url) throws IOException
HttpClientget 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse get(String url, Map<String,String> params) throws IOException
HttpClientget 在接口中 HttpClienturl - request urlparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse get(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientget 在接口中 HttpClienturl - request urlheaders - request headers mapparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse post(String url) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse post(String url, Map<String,String> params) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse post(String url, String json) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urljson - request json stringIOException - if I/O errors occurpublic HttpResponse post(String url, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlstream - stream stringcontentType - httpclient ContentTypeIOException - if I/O errors occurpublic HttpResponse post(String url, Map<String,String> headers, String json) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlheaders - request headers mapjson - json stringIOException - if I/O errors occurpublic HttpResponse post(String url, Map<String,String> headers, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlheaders - request hreaders mapstream - stream stringcontentType - httpclient ContentTypeIOException - if I/O errors occurpublic HttpResponse post(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientpost 在接口中 HttpClienturl - request urlheaders - request hreaders mapparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse put(String url) throws IOException
HttpClientput 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse put(String url, Map<String,String> params) throws IOException
HttpClientput 在接口中 HttpClienturl - request urlparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse put(String url, String json) throws IOException
HttpClientput 在接口中 HttpClienturl - request urljson - request json stringIOException - if I/O errors occurpublic HttpResponse put(String url, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientput 在接口中 HttpClienturl - the urlstream - the streamcontentType - the contentTypeIOExceptionpublic HttpResponse put(String url, Map<String,String> headers, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientput 在接口中 HttpClienturl - the urlstream - the streamcontentType - the contentTypeIOExceptionpublic HttpResponse put(String url, Map<String,String> headers, String json) throws IOException
HttpClientput 在接口中 HttpClienturl - request urlheaders - request headers mapjson - json stringIOException - if I/O errors occurpublic HttpResponse put(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientput 在接口中 HttpClienturl - request urlheaders - request hreaders mapparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse delete(String url) throws IOException
HttpClientdelete 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse delete(String url, Map<String,String> params) throws IOException
HttpClientdelete 在接口中 HttpClienturl - request urlparams - request params mapIOException - if I/O errors occurpublic HttpResponse delete(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientdelete 在接口中 HttpClienturl - request urlheaders - request headers mapparams - the paramsIOException - if I/O errors occurpublic HttpResponse patch(String url) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlIOException - IOException if I/O errors occurpublic HttpResponse patch(String url, Map<String,String> params) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse patch(String url, String json) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urljson - request json stringIOException - if I/O errors occurpublic HttpResponse patch(String url, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlstream - stream stringcontentType - httpclient ContentTypeIOException - if I/O errors occurpublic HttpResponse patch(String url, Map<String,String> headers, String json) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlheaders - request headers mapjson - json stringIOException - if I/O errors occurpublic HttpResponse patch(String url, Map<String,String> headers, String stream, org.apache.http.entity.ContentType contentType) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlheaders - request hreaders mapstream - stream stringcontentType - httpclient ContentTypeIOException - if I/O errors occurpublic HttpResponse patch(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientpatch 在接口中 HttpClienturl - request urlheaders - request hreaders mapparams - request parameter mapIOException - if I/O errors occurpublic HttpResponse head(String url) throws IOException
HttpClienthead 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse head(String url, Map<String,String> params) throws IOException
HttpClienthead 在接口中 HttpClienturl - request urlparams - request params mapIOException - if I/O errors occurpublic HttpResponse head(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClienthead 在接口中 HttpClienturl - request urlheaders - request headers mapparams - the paramsIOException - if I/O errors occurpublic HttpResponse options(String url) throws IOException
HttpClientoptions 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse options(String url, Map<String,String> params) throws IOException
HttpClientoptions 在接口中 HttpClienturl - request urlparams - request params mapIOException - if I/O errors occurpublic HttpResponse options(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClientoptions 在接口中 HttpClienturl - request urlheaders - request headers mapparams - the paramsIOException - if I/O errors occurpublic HttpResponse trace(String url) throws IOException
HttpClienttrace 在接口中 HttpClienturl - request urlIOException - if I/O errors occurpublic HttpResponse trace(String url, Map<String,String> params) throws IOException
HttpClienttrace 在接口中 HttpClienturl - request urlparams - request params mapIOException - if I/O errors occurpublic HttpResponse trace(String url, Map<String,String> headers, Map<String,String> params) throws IOException
HttpClienttrace 在接口中 HttpClienturl - request urlheaders - request headers mapparams - the paramsIOException - if I/O errors occurpublic HttpResponse execute(RequestMethod requestMethod, String url) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, Map<String,String> params) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, String json) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, Map<String,String> headers, Map<String,String> params) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, Map<String,String> headers, String json) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, String stream, org.apache.http.entity.ContentType contentType) throws IOException
execute 在接口中 HttpClientIOExceptionpublic HttpResponse execute(RequestMethod requestMethod, String url, Map<String,String> headers, String stream, org.apache.http.entity.ContentType contentType) throws IOException
execute 在接口中 HttpClientIOExceptionCopyright © 2015–2016. All rights reserved.