Pre Merge pull request !13 from 坎坎坷坷/N/A

This commit is contained in:
坎坎坷坷 2024-11-18 04:35:29 +00:00 committed by Gitee
commit fe06c87563
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
1 changed files with 8 additions and 0 deletions

View File

@ -77,6 +77,14 @@ public final class HttpUtils {
return handlerRequest(httpGet);
}
public static String getRemoteUrl(String url){
HttpGet httpGet = new HttpGet(url);
httpGet.setHeader(HttpHeaders.USER_AGENT, USER_AGENT);
httpGet.setHeader(HttpHeaders.CONTENT_TYPE, CONTENT_TYPE);
httpGet.setConfig(getDefaultConfig());
return handlerRequest(httpGet);
}
/**
* post json请求
*