FileDocCategorySizeDatePackage
IdentityHashMap.javaAPI DocApache Axis 1.41958Sat Apr 22 18:57:28 BST 2006org.apache.axis.utils

IdentityHashMap

public class IdentityHashMap extends HashMap
IdentityHashMap similar to JDK1.4's java.util.IdentityHashMap
author
Davanum Srinivas

Fields Summary
Constructors Summary
public IdentityHashMap(int initialCapacity, float loadFactor)
Constructor for IdentityHashMap.

param
initialCapacity
param
loadFactor

        super(initialCapacity, loadFactor);
    
public IdentityHashMap(int initialCapacity)
Constructor for IdentityHashMap.

param
initialCapacity

        super(initialCapacity);
    
public IdentityHashMap()
Constructor for IdentityHashMap.

        super();
    
public IdentityHashMap(Map t)
Constructor for IdentityHashMap.

param
t

        super(t);
    
Methods Summary
public java.lang.Objectadd(java.lang.Object value)
adds an object to the Map. new Identity(obj) is used as key

        Object key = new IDKey(value);
        if (! super.containsKey(key))
        {
            return super.put(key, value);
        }
        else return null;

    
public booleancontainsKey(java.lang.Object key)

see
Map#containsKey(Object)

        return super.containsKey(new IDKey(key));
    
public java.lang.Objectget(java.lang.Object key)

see
Map#get(Object)

        return super.get(new IDKey(key));
    
public java.lang.Objectput(java.lang.Object key, java.lang.Object value)

see
Map#put(Object, Object)

        return super.put(new IDKey(key), value);
    
public java.lang.Objectremove(java.lang.Object key)

see
Map#remove(Object)

        return super.remove(new IDKey(key));