Package com.luna.common.net.high
Class HttpHighLevelUtil
java.lang.Object
com.luna.common.net.high.HttpHighLevelUtil
- Author:
- luna
- Description:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final org.apache.hc.core5.http.impl.bootstrap.RequesterBootstrap
static org.apache.hc.core5.http.impl.bootstrap.HttpRequester
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic <T> T
doDelete
(String host, String path, Map<String, String> headers, Map<String, String> queries, org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler) static <T> T
doGet
(String host, String path, Map<String, String> headers, Map<String, String> queries, org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler) static <T> T
doPost
(String host, String path, Map<String, String> headers, Map<String, String> queries, org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler) static <T> T
doPut
(String host, String path, Map<String, String> headers, Map<String, String> queries, org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler) static <T> T
doRequest
(org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler, org.apache.hc.core5.http.HttpHost httpHost, org.apache.hc.client5.http.classic.methods.HttpUriRequestBase httpUriRequestBase) static org.apache.hc.core5.http.HttpHost
static void
init()
static void
setProxy
(int port) static void
-
Field Details
-
BOOTSTRAP
public static final org.apache.hc.core5.http.impl.bootstrap.RequesterBootstrap BOOTSTRAP -
HTTP_REQUESTER
public static org.apache.hc.core5.http.impl.bootstrap.HttpRequester HTTP_REQUESTER
-
-
Constructor Details
-
HttpHighLevelUtil
public HttpHighLevelUtil()
-
-
Method Details
-
init
public static void init() -
setProxy
public static void setProxy(int port) -
setProxy
-
getHost
-
doGet
-
doPost
-
doDelete
-
doPut
-
doRequest
public static <T> T doRequest(org.apache.hc.core5.http.io.HttpClientResponseHandler<T> responseHandler, org.apache.hc.core5.http.HttpHost httpHost, org.apache.hc.client5.http.classic.methods.HttpUriRequestBase httpUriRequestBase)
-