public class HttpUtil extends Object
| Constructor and Description |
|---|
HttpUtil(Integer connTimeout,
Integer readTimeout,
Integer writeTimeout) |
| Modifier and Type | Method and Description |
|---|---|
String |
doRequest(okhttp3.Request request) |
String |
getRequest(String url) |
String |
getRequest(String url,
okhttp3.Headers headers) |
String |
postRequest(String url,
byte[] body,
okhttp3.Headers headers) |
String |
postRequest(String url,
String body) |
String |
postRequest(String url,
String body,
okhttp3.Headers headers) |
public String doRequest(okhttp3.Request request) throws IOException
IOExceptionpublic String getRequest(String url) throws SDKException, IOException
SDKExceptionIOExceptionpublic String getRequest(String url, okhttp3.Headers headers) throws SDKException, IOException
SDKExceptionIOExceptionpublic String postRequest(String url, String body) throws SDKException, IOException
SDKExceptionIOExceptionpublic String postRequest(String url, String body, okhttp3.Headers headers) throws SDKException, IOException
SDKExceptionIOExceptionpublic String postRequest(String url, byte[] body, okhttp3.Headers headers) throws SDKException, IOException
SDKExceptionIOExceptionCopyright © 2025. All rights reserved.