标签:current asn nbsp keyset 替换 ext class 集合 shm
1.遍历key-Value
ConcurrentHashMap<String, Object> map= new ConcurrentHashMap<String, Object>();//Object替换为结构类 for(String key :map.keySet()){ Object object= map.get(key); }
2.遍历Value
ConcurrentHashMap<String, Object> map= new ConcurrentHashMap<String, Object>();//Object替换为结构类 Iterator<Entry<String, Object>> it = map.entrySet().iterator(); while (it.hasNext()) { Entry<String, Object> entry = (Entry<String, Object>) it.next(); Object object= entry.getValue(); }
标签:current asn nbsp keyset 替换 ext class 集合 shm
原文地址:https://www.cnblogs.com/it-mh/p/10438163.html