取Map 里的key

Map map = new HashMap();
for (Iterator iter = map.entrySet().iterator(); iter.hasNext();)
{
	Map.Entry entry = (Map.Entry)iter.next();
	String key = (String)entry.getKey();
	String value = (String)map.get(key);
}

你可能感兴趣的:(java)