public static void getJson(){
StringBuffer document = new StringBuffer();
try{
URL url = new URL("http://www.weather.com.cn/data/sk/101010100.html");//远程url
URLConnection conn = url.openConnection();
BufferedReader reader = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line = null;
while ((line = reader.readLine()) != null)
document.append(line + " ");
reader.close();
}catch(MalformedURLException e) {
e.printStackTrace();
}catch(IOException e){
e.printStackTrace(); }
System.out.println(document.toString());//返回值
}