java怎么通过url获得json数据并解析出来

如题所述

第1个回答  2018-05-20
String json = "{\"test\",\"hello world\"}";

JSONObject jsonObject = net.sf.json.JSONObject.fromObject(json);
System.out.println(jsonObject.getString("test"));
//打印hello world本回答被网友采纳
相似回答