Map,可用常规的for遍历
Map<String, String> bmarks = new HashMap<>(); for (Map.Entry<String, String> entry: bmarks.entrySet()) { System.out.println(entry.getKey() + " : " + entry.getValue()); }
其他遍历方式,参考:http://blog.csdn.net/tjcyjd/article/details/11111401