Packageorg.servebox.commons.map
Classpublic class Hashtable
ImplementsIMap

This class is a port of the Java hashtable, which maps keys to values. Any non-null object can be used as a key or as a value.



Public Methods
 MethodDefined by
  
Creates a new Hashtable object.
Hashtable
  
clear():void
Removes all mappings from this map (optional operation).
Hashtable
  
Creates a shallow copy of this hashtable.
Hashtable
  
contains(value:IBasicObject):Boolean
Hashtable
  
containsKey(key:Object):Boolean
Returns true if this map contains a mapping for the specified key.
Hashtable
  
containsValue(value:IBasicObject):Boolean
Returns true if this map maps one or more keys to the specified value.
Hashtable
  
elements():Array
Hashtable
  
equals(value:IBasicObject):Boolean
Object comparison mechanism.
Hashtable
  
get(key:Object):IBasicObject
Hashtable
  
hashCode():int
Returns the hashcode of the object.
Hashtable
  
isEmpty():Boolean
Returns true if this map contains no key-value mappings.
Hashtable
  
keys():Array
Returns a view of the keys contained in this map.
Hashtable
  
keySet():Array
Returns a view of the keys contained in this map.
Hashtable
  
needleMap(neededKeys:Array):IMap
Copies the key/values pair using the specified set of keys to a new map instance.
Hashtable
  
put(key:Object, value:IBasicObject):Object
Maps the specified key to the specified value in this Hashtable.
Hashtable uses key.hashCode to store and retrieve values.
Keys should implement a hashCode() : int method, or the Hashtable will throw an Error.
Hashtable
  
putAll(t:IMap):void
Copies all of the mappings from the specified map to this map (optional operation).
Hashtable
  
remove(key:Object):Object
Removes the mapping for this key from this map if present (optional operation).
Hashtable
  
size():int
Returns the number of key-value mappings in this map.
Hashtable
  
toString():String
Returns the string representation of the specified object.
Hashtable
  
values():Array
Returns a collection view of the values contained in this map.
Hashtable
Constructor detail
Hashtable()constructor
public function Hashtable()

Creates a new Hashtable object.

Method detail
clear()method
public function clear():void

Removes all mappings from this map (optional operation).

clone()method 
public function clone():Hashtable

Creates a shallow copy of this hashtable.

Returns
Hashtable
contains()method 
public function contains(value:IBasicObject):Boolean

Parameters
value:IBasicObject

Returns
Boolean
containsKey()method 
public function containsKey(key:Object):Boolean

Returns true if this map contains a mapping for the specified key.

Parameters
key:Object

Returns
Boolean
containsValue()method 
public function containsValue(value:IBasicObject):Boolean

Returns true if this map maps one or more keys to the specified value.

Parameters
value:IBasicObject

Returns
Boolean
elements()method 
public function elements():Array

Returns
Array
equals()method 
public function equals(value:IBasicObject):Boolean

Object comparison mechanism. By default, the comparison is performed using the == operator. The definition of your own equals method is strongly encouraged.

Parameters
value:IBasicObject

Returns
Boolean
get()method 
public function get(key:Object):IBasicObject

Parameters
key:Object

Returns
IBasicObject
hashCode()method 
public function hashCode():int

Returns the hashcode of the object.

Returns
int
isEmpty()method 
public function isEmpty():Boolean

Returns true if this map contains no key-value mappings.

Returns
Boolean
keys()method 
public function keys():Array

Returns a view of the keys contained in this map.

Returns
Array
keySet()method 
public function keySet():Array

Returns a view of the keys contained in this map.

Returns
Array
needleMap()method 
public function needleMap(neededKeys:Array):IMap

Copies the key/values pair using the specified set of keys to a new map instance.

Parameters
neededKeys:Array

Returns
IMap
put()method 
public function put(key:Object, value:IBasicObject):Object

Maps the specified key to the specified value in this Hashtable.
Hashtable uses key.hashCode to store and retrieve values.
Keys should implement a hashCode() : int method, or the Hashtable will throw an Error.

Parameters
key:Object
 
value:IBasicObject

Returns
Object
putAll()method 
public function putAll(t:IMap):void

Copies all of the mappings from the specified map to this map (optional operation).

Parameters
t:IMap
remove()method 
public function remove(key:Object):Object

Removes the mapping for this key from this map if present (optional operation).

Parameters
key:Object

Returns
Object
size()method 
public function size():int

Returns the number of key-value mappings in this map.

Returns
int
toString()method 
public function toString():String

Returns the string representation of the specified object.

Returns
String
values()method 
public function values():Array

Returns a collection view of the values contained in this map.

Returns
Array