List 转 String的问题
List<Map> thirdAwardUserList;
经过程序之后
System.out.println(thirdAwardUserList.toString());
显示如下:
[{tel=13512345679, name=张2}, {tel=13512345681, name=张4}, {tel=13512345688, name=张11}, {tel=13512345700, name=张23}, {tel=13512345685, name=张8}, {tel=13512345689, name=张12}]
但是我只要得到tel和name 如13512345678,张1
怎么解决
------解决方案--------------------
Java code
for(Map map : thirdAwardUserList){
System.out.println("tel:" + map.get("tel").toString() + " name:" + map.get("name").toString());
}