wt.fc.collections
Class WTKeyedHashMap

java.lang.Object
  extended by java.util.AbstractMap
      extended by wt.fc.collections.WTKeyedHashMap
All Implemented Interfaces:
Externalizable, Serializable, Cloneable, Map, WTKeyedMap, ResultProcessor
Direct Known Subclasses:
WTValuedHashMap

public class WTKeyedHashMap
extends AbstractMap
implements Cloneable, WTKeyedMap, ResultProcessor, Externalizable

Follows the patterns established by the default collection implementations. The implementation of ResultProcessor.addElement(Object) uses the following algorithm:



Supported API: true

Extendable: false

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface wt.fc.collections.WTKeyedMap
wt.fc.collections.WTKeyedMap.WTEntry
 
Nested classes/interfaces inherited from interface java.util.Map
Map.Entry<K,V>
 
Constructor Summary
WTKeyedHashMap()
          

Supported API: true
WTKeyedHashMap(int initial_capacity)
          

Supported API: true
WTKeyedHashMap(int initial_capacity, int key_mask)
          

Supported API: true
WTKeyedHashMap(Map m)
          

Supported API: true
WTKeyedHashMap(Map m, int key_mask)
          

Supported API: true
 
Method Summary
 void addElement(Object anObj)
          This method is called by the low level persistence layer to add the specified object to the result.
 Object clone()
          

Supported API: true
 WTKeyedHashMap clone(boolean deep)
          

Supported API: true
 boolean equals(Object o)
          

Supported API: true
 Object get(Persistable p)
          

Supported API: true
 boolean isEmpty()
          

Supported API: true
 
Methods inherited from class java.util.AbstractMap
toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

WTKeyedHashMap

public WTKeyedHashMap()


Supported API: true


WTKeyedHashMap

public WTKeyedHashMap(int initial_capacity)


Supported API: true

Parameters:
initial_capacity -

WTKeyedHashMap

public WTKeyedHashMap(int initial_capacity,
                      int key_mask)


Supported API: true

Parameters:
initial_capacity -
key_mask -

WTKeyedHashMap

public WTKeyedHashMap(Map m)


Supported API: true

Parameters:
m -

WTKeyedHashMap

public WTKeyedHashMap(Map m,
                      int key_mask)


Supported API: true

Parameters:
m -
key_mask -
Method Detail

clone

public Object clone()


Supported API: true

Overrides:
clone in class AbstractMap
Returns:
Object

clone

public WTKeyedHashMap clone(boolean deep)


Supported API: true

Parameters:
deep -
Returns:
WTKeyedHashMap

equals

public boolean equals(Object o)


Supported API: true

Specified by:
equals in interface Map
Specified by:
equals in interface WTKeyedMap
Overrides:
equals in class AbstractMap
Parameters:
o -
Returns:
boolean

get

public Object get(Persistable p)


Supported API: true

Specified by:
get in interface WTKeyedMap
Parameters:
p -
Returns:
Object

isEmpty

public boolean isEmpty()


Supported API: true

Specified by:
isEmpty in interface Map
Specified by:
isEmpty in interface WTKeyedMap
Overrides:
isEmpty in class AbstractMap
Returns:
boolean

addElement

public void addElement(Object anObj)
                throws WTException
This method is called by the low level persistence layer to add the specified object to the result. The actual type of the object is based on the type of query. It may be a Persistable or an Object[].

Supported API: true

Specified by:
addElement in interface ResultProcessor
Parameters:
anObj - Result object to add.
Throws:
WTException - - if the object can't be added to the result
WTException