From e8e342cd6c1334f1b8f71d24baa3157637a9ac43 Mon Sep 17 00:00:00 2001
From: admin <weikou2014>
Date: 星期四, 04 二月 2021 19:33:26 +0800
Subject: [PATCH] 完善PPTV

---
 src/main/java/com/yeshi/buwan/util/HttpUtil.java |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/src/main/java/com/yeshi/buwan/util/HttpUtil.java b/src/main/java/com/yeshi/buwan/util/HttpUtil.java
index e7abef6..4036f74 100644
--- a/src/main/java/com/yeshi/buwan/util/HttpUtil.java
+++ b/src/main/java/com/yeshi/buwan/util/HttpUtil.java
@@ -36,6 +36,22 @@
 		return "";
 	}
 
+
+	public static String defaultGet(String url) {
+		HttpClient client = new HttpClient();
+		GetMethod method = new GetMethod(url);
+		try {
+			client.executeMethod(method);
+			method.getStatusCode();
+			return method.getResponseBodyAsString();
+		} catch (HttpException e) {
+			e.printStackTrace();
+		} catch (IOException e) {
+			e.printStackTrace();
+		}
+		return "";
+	}
+
 	public static String get(String url, Map<String, String> map) {
 		HttpClient client = new HttpClient();
 		// client.getHostConfiguration().setProxy("192.168.1.122", 8888);

--
Gitblit v1.8.0