Package jadex.commons.collection
Class FastHashMap
- java.lang.Object
-
- jadex.commons.collection.FastHashMap
-
- All Implemented Interfaces:
java.io.Serializable
,java.util.Map
public class FastHashMap extends java.lang.Object implements java.util.Map, java.io.Serializable
Implements a map from strings to objects as a hash table.null
key is allowed;null
values are allowed.- Since:
- Aug 30, 2005
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description FastHashMap()
Constructor for Message.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
boolean
containsKey(java.lang.Object key)
boolean
containsValue(java.lang.Object value)
java.util.Set
entrySet()
java.lang.Object
get(java.lang.Object key)
java.lang.Object[]
getKeys()
boolean
isEmpty()
java.util.Set
keySet()
java.lang.Object
put(java.lang.Object key, java.lang.Object value)
void
putAll(java.util.Map map)
java.lang.Object
remove(java.lang.Object key)
int
size()
java.lang.String
toString()
java.util.Collection
values()
-
-
-
Method Detail
-
put
public java.lang.Object put(java.lang.Object key, java.lang.Object value)
- Specified by:
put
in interfacejava.util.Map
- Parameters:
key
-value
-- Returns:
- the old value or null
-
get
public java.lang.Object get(java.lang.Object key)
- Specified by:
get
in interfacejava.util.Map
- Parameters:
key
-- Returns:
- the object for this key or null
-
containsKey
public boolean containsKey(java.lang.Object key)
- Specified by:
containsKey
in interfacejava.util.Map
- Parameters:
key
-- Returns:
- true if there is a key of this kind
-
getKeys
public java.lang.Object[] getKeys()
- Returns:
- the keys from this message
-
size
public int size()
- Specified by:
size
in interfacejava.util.Map
- Returns:
- The size of the map.
- See Also:
Map.size()
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfacejava.util.Map
- Returns:
- True, if the map is empty.
- See Also:
Map.isEmpty()
-
containsValue
public boolean containsValue(java.lang.Object value)
- Specified by:
containsValue
in interfacejava.util.Map
- Parameters:
value
-- Returns:
- True, if the value was found.
- See Also:
Map.containsValue(java.lang.Object)
-
remove
public java.lang.Object remove(java.lang.Object key)
- Specified by:
remove
in interfacejava.util.Map
- Parameters:
key
-- Returns:
- The object associated to the key.
- See Also:
Map.remove(java.lang.Object)
-
putAll
public void putAll(java.util.Map map)
- Specified by:
putAll
in interfacejava.util.Map
- Parameters:
map
-- See Also:
Map.putAll(java.util.Map)
-
clear
public void clear()
- Specified by:
clear
in interfacejava.util.Map
- See Also:
Map.clear()
-
keySet
public java.util.Set keySet()
- Specified by:
keySet
in interfacejava.util.Map
- Returns:
- The key set.
- See Also:
Map.keySet()
-
values
public java.util.Collection values()
- Specified by:
values
in interfacejava.util.Map
- Returns:
- The values.
- See Also:
Map.values()
-
entrySet
public java.util.Set entrySet()
- Specified by:
entrySet
in interfacejava.util.Map
- Returns:
- The set of entries.
- See Also:
Map.entrySet()
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
- Returns:
- the string representation of this message
- See Also:
Object.toString()
-
-