package java.util; //抽象类,所有key-value键值对(HashTable)的父类, public abstract class Dictionary<K,V> { public Dictionary() { } abstract public int size(); //键值对size abstract public boolean isEmpty(); //判断是否空 abstract public Enumeration<K> keys(); //key构成枚举类 abstract public Enumeration<V> elements(); //value构成枚举类 abstract public V get(Object key); //由key获取value abstract public V put(K key, V value);//将key-value放入到字典中 abstract public V remove(Object key);//移除一个键值对 }