@Component public class HttpClientUtil extends Object
| 限定符和类型 | 类和说明 |
|---|---|
static class |
HttpClientUtil.HttpDeleteWithBody |
| 构造器和说明 |
|---|
HttpClientUtil() |
| 限定符和类型 | 方法和说明 |
|---|---|
static String |
delete(Map<String,String> headers,
String url,
com.alibaba.fastjson.JSONObject params)
delete,params可为null,headers可为null
|
static String |
get(Map<String,String> headers,
String url,
com.alibaba.fastjson.JSONObject params)
get请求,params可为null,headers可为null
|
static String |
post(Map<String,String> headers,
String url,
com.alibaba.fastjson.JSONObject params)
post请求,params可为null,headers可为null
|
static String |
put(Map<String,String> headers,
String url,
com.alibaba.fastjson.JSONObject params)
put,params可为null,headers可为null
|
public static String get(Map<String,String> headers, String url, com.alibaba.fastjson.JSONObject params) throws IOException
headers - 请求头url - 地址params - 参数IOException - io出错public static String post(Map<String,String> headers, String url, com.alibaba.fastjson.JSONObject params) throws IOException
headers - 请求头url - 地址params - 参数IOException - io出错public static String delete(Map<String,String> headers, String url, com.alibaba.fastjson.JSONObject params) throws IOException
headers - 请求头url - 地址params - 参数IOException - io出错public static String put(Map<String,String> headers, String url, com.alibaba.fastjson.JSONObject params) throws IOException
headers - 请求头url - 地址params - 参数IOException - io出错Copyright © 2021. All Rights Reserved.