java alibaba fastJson 遍历数组取值循环等
fastjson
FASTJSON 2.0.x has been released, faster and more secure, recommend you upgrade.
项目地址:https://gitcode.com/gh_mirrors/fastj/fastjson
免费下载资源
·
一、引入的jar包
import com.alibaba.fastjson.JSON;
二、取值循环
String str= " [{"sort":"1","item":"单选1","value":"答案一"},{"sort":2,"item":"选项2","value":"答案二"}]";
List<HashMap> list =JSON.parseArray(str, HashMap.class);
for (Map<String,Object> hashMap : list) {
System.out.println(hashMap);
String item=(String) hashMap.get("item");
}
GitHub 加速计划 / fastj / fastjson
25.69 K
6.51 K
下载
FASTJSON 2.0.x has been released, faster and more secure, recommend you upgrade.
最近提交(Master分支:3 个月前 )
c942c834 - 1 年前
5bc4709b - 1 年前
更多推荐
已为社区贡献5条内容
所有评论(0)