jdk/src/share/classes/java/util/WeakHashMap.java
changeset 56 48451b4616e8
parent 2 90ce3da70b43
child 65 51fc1d79463f
equal deleted inserted replaced
55:5ecee29e98d8 56:48451b4616e8
    27 import java.lang.ref.WeakReference;
    27 import java.lang.ref.WeakReference;
    28 import java.lang.ref.ReferenceQueue;
    28 import java.lang.ref.ReferenceQueue;
    29 
    29 
    30 
    30 
    31 /**
    31 /**
    32  * A hashtable-based <tt>Map</tt> implementation with <em>weak keys</em>.
    32  * Hash table based implementation of the <tt>Map</tt> interface, with
       
    33  * <em>weak keys</em>.
    33  * An entry in a <tt>WeakHashMap</tt> will automatically be removed when
    34  * An entry in a <tt>WeakHashMap</tt> will automatically be removed when
    34  * its key is no longer in ordinary use.  More precisely, the presence of a
    35  * its key is no longer in ordinary use.  More precisely, the presence of a
    35  * mapping for a given key will not prevent the key from being discarded by the
    36  * mapping for a given key will not prevent the key from being discarded by the
    36  * garbage collector, that is, made finalizable, finalized, and then reclaimed.
    37  * garbage collector, that is, made finalizable, finalized, and then reclaimed.
    37  * When a key has been discarded its entry is effectively removed from the map,
    38  * When a key has been discarded its entry is effectively removed from the map,