refactor
This commit is contained in:
parent
1c327e5832
commit
1b44489b20
@ -22,7 +22,8 @@ public class HttpHelper {
|
|||||||
conn.setDoInput(true);
|
conn.setDoInput(true);
|
||||||
conn.setDoOutput(false);
|
conn.setDoOutput(false);
|
||||||
conn.setConnectTimeout(timeout);
|
conn.setConnectTimeout(timeout);
|
||||||
conn.setRequestProperty("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1700.76 Safari/537.36");
|
conn.setRequestProperty("User-Agent",
|
||||||
|
"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1700.76 Safari/537.36");
|
||||||
conn.connect();
|
conn.connect();
|
||||||
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
|
BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
|
||||||
String inputLine;
|
String inputLine;
|
||||||
@ -35,5 +36,4 @@ public class HttpHelper {
|
|||||||
}
|
}
|
||||||
return output;
|
return output;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user