danger.util
Class IdentityHashtable
java.lang.Object
java.util.Dictionary
danger.util.IdentityHashtable
- All Implemented Interfaces:
- Serializable, Cloneable, Map
public class IdentityHashtable
- extends Dictionary
- implements Map, Cloneable, Serializable
An implementation of the J2SE IdentityHashMap class, using
the Hashtable interface for CLDC consistency. Keys are hashed
using System.identityHashCode(key), instead of
key.hashCode(), and reference equality is used instead of
key.equals(key2).
This class is thread-safe.
- See Also:
IdentityHashMap,
Serialized Form
| Nested classes/interfaces inherited from interface java.util.Map |
Map.Entry<K,V> |
IdentityHashtable
public IdentityHashtable()
IdentityHashtable
public IdentityHashtable(int expectedMaxSize)
IdentityHashtable
public IdentityHashtable(Map m)
clear
public void clear()
- Specified by:
clear in interface Map
clone
public Object clone()
- Overrides:
clone in class Object
contains
public boolean contains(Object value)
containsKey
public boolean containsKey(Object key)
- Specified by:
containsKey in interface Map
containsValue
public boolean containsValue(Object value)
- Specified by:
containsValue in interface Map
elements
public Enumeration elements()
- Specified by:
elements in class Dictionary
entrySet
public Set entrySet()
- Specified by:
entrySet in interface Map
equals
public boolean equals(Object o)
- Specified by:
equals in interface Map- Overrides:
equals in class Object
get
public Object get(Object key)
- Specified by:
get in interface Map- Specified by:
get in class Dictionary
hashCode
public int hashCode()
- Specified by:
hashCode in interface Map- Overrides:
hashCode in class Object
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty in interface Map- Specified by:
isEmpty in class Dictionary
keys
public Enumeration keys()
- Specified by:
keys in class Dictionary
keySet
public Set keySet()
- Specified by:
keySet in interface Map
put
public Object put(Object key,
Object value)
- Specified by:
put in interface Map- Specified by:
put in class Dictionary
putAll
public void putAll(Map t)
- Specified by:
putAll in interface Map
remove
public Object remove(Object key)
- Specified by:
remove in interface Map- Specified by:
remove in class Dictionary
size
public int size()
- Specified by:
size in interface Map- Specified by:
size in class Dictionary
toString
public String toString()
- Overrides:
toString in class Object
values
public Collection values()
- Specified by:
values in interface Map