public class JdkHttpUtils extends AbstractHttpUtils implements HttpUtils
| 限定符和类型 | 类和说明 |
|---|---|
static class |
JdkHttpUtils.FormBody |
static class |
JdkHttpUtils.FormDataBody |
_bodyRaw, _charset, _cookies, _enablePrintln, _files, _headers, _multipart, _params, _proxy, _serializer, _timeout, _url| 构造器和说明 |
|---|
JdkHttpUtils(java.lang.String url) |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
allowMethods(java.lang.String... methods)
补丁,增加新方法支持
|
static void |
allowPatch()
允许 PATCH 方法
|
protected HttpResponse |
execDo(java.lang.String _method,
java.util.concurrent.CompletableFuture<HttpResponse> future) |
protected HttpResponse |
getResponse(java.net.HttpURLConnection _builder,
java.lang.String method) |
protected java.net.HttpURLConnection |
openConnection(java.lang.String newUrl) |
protected HttpResponse |
request(java.net.HttpURLConnection _builder,
java.lang.String method) |
protected java.lang.String |
urlRebuild(java.lang.String method,
java.lang.String url,
java.nio.charset.Charset charset) |
body, body, body, bodyOfBean, charset, cookie, cookieAdd, cookies, cookies, data, data, data, data, data, delete, deleteAs, enablePrintln, exec, execAsBody, execAsBody, execAsCode, execAsLineStream, execAsSseStream, execAsync, get, getAs, getRequestCookieString, head, header, headerAdd, headers, headers, isRedirected, multipart, options, patch, patchAs, post, postAs, proxy, put, putAs, serializer, serializer, timeout, tryInitCookies, tryInitFiles, tryInitHeaders, tryInitParams, userAgentclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaccept, body, body, body, body, body, bodyJson, bodyOfBean, bodyOfJson, bodyOfTxt, bodyRaw, bodyRaw, bodyRaw, bodyRaw, bodyTxt, bodyTxt, charset, contentType, cookie, cookieAdd, cookies, cookies, data, data, data, data, data, data, delete, deleteAs, enablePrintln, exec, execAsBody, execAsBody, execAsCode, execAsEventStream, execAsLineStream, execAsSseStream, execAsTextStream, execAsync, get, getAs, head, header, headerAdd, headers, headers, http, http, http, multipart, options, patch, patchAs, post, post, postAs, postAs, proxy, proxy, put, putAs, serializer, serializer, timeout, timeout, timeout, toQueryString, toQueryString, urlEncode, urlEncode, userAgentprotected HttpResponse execDo(java.lang.String _method, java.util.concurrent.CompletableFuture<HttpResponse> future) throws java.io.IOException
execDo 在类中 AbstractHttpUtilsjava.io.IOExceptionprotected java.net.HttpURLConnection openConnection(java.lang.String newUrl)
throws java.io.IOException
java.io.IOExceptionprotected HttpResponse request(java.net.HttpURLConnection _builder, java.lang.String method) throws java.io.IOException
java.io.IOExceptionprotected HttpResponse getResponse(java.net.HttpURLConnection _builder, java.lang.String method) throws java.io.IOException
java.io.IOExceptionprotected java.lang.String urlRebuild(java.lang.String method,
java.lang.String url,
java.nio.charset.Charset charset)
throws java.io.UnsupportedEncodingException
java.io.UnsupportedEncodingExceptionpublic static void allowPatch()
public static void allowMethods(java.lang.String... methods)