原文:java 字符串转成 json 数组并且遍历

当需要把一串字符串转成一个json 数组 ,并遍历其中的内容时。 首先要导入net.sf.json.JSONArray和net.sf.json.JSONObject 两个jar 包 lt dependency gt lt groupId gt net.sf.json lib lt groupId gt lt artifactId gt json lib lt artifactId gt lt ve ...

2018-10-09 09:31 0 31951 推荐指数:

查看详情

java 字符串转成 json 数组并且遍历

当需要把一字符串转成一个json 数组 ,并遍历其中的内容时。 首先要导入 net.sf.json.JSONArray和net.sf.json.JSONObject 两个jar 包 String str = "[{name:'a',value:'aa'},{name:'b',value ...

Sun Oct 09 19:43:00 CST 2016 0 33760
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM