HashTable |
A hash table using linked overflow for collision resolving. Depricated, use the HashMap class instead.
| HashTable | A hash table using linked overflow for collision resolving. |
| Functions and Properties | |
| hashString | A simple function for hashing strings. |
| hashInt | A simple function for hashing integers. |
| HashTable | Initializes a new hash table. |
| maxSize | The hash table’s maximum capacity. |
| insert | Inserts a key/data couple into the table. |
| find | Finds the entry that is associated with the given key. |
| remove | Removes an entry based on a given key. |
| contains | @inheritDoc |
| clear | @inheritDoc |
| getIterator | @inheritDoc |
| size | @inheritDoc |
| isEmpty | @inheritDoc |
| toArray | @inheritDoc |
| toString | Prints out a string representing the current object. |
| dump | Prints out all elements (for debug/demo purposes). |
| HashEntry | Simple container class for storing a key/data couple. |
A simple function for hashing strings.
public static function hashString( s: String ):int
A simple function for hashing integers.
public static function hashInt( i: int ):int
Initializes a new hash table.
public function HashTable( size: int, hash: Function = null )
The hash table’s maximum capacity.
public function get maxSize():int
Inserts a key/data couple into the table.
public function insert( key: *, obj: * ):void
Finds the entry that is associated with the given key.
public function find( key: * ):*
Removes an entry based on a given key.
public function remove( key: * ):*
@inheritDoc
public function contains( obj: * ):Boolean
@inheritDoc
public function clear():void
@inheritDoc
public function getIterator():Iterator
@inheritDoc
public function get size():int
@inheritDoc
public function isEmpty():Boolean
@inheritDoc
public function toArray():Array
Prints out a string representing the current object.
public function toString():String
Prints out all elements (for debug/demo purposes).
public function dump():String