java.util.IdentityHashMap.values() 方法


java.util.IdentityHashMap.values() 方法

package com.codingdict;

import java.util.*;

public class IdentityHashMapDemo {
   public static void main(String args[]) {

      // create identity hash
      IdentityHashMap ihmap = new IdentityHashMap();

      // populate the ihmap
      ihmap.put(1, "java");
      ihmap.put(2, "util");
      ihmap.put(3, "package");      

      System.out.println("Map values: " + ihmap);
      System.out.println("Collection view of the map: " + ihmap.values());
   }    
}