inherits
variables
Thirty-two bits by which to multiply a hashvalue to make all bits, more or less, significant.
This (unsigned) value is (1 << 32) * frac (0.5 + 0.5 * sqrt (5)). The value of which the fractional part is taken is the golden ratio. (0x9e3779b9).
variables
The number of stored objects.
The 2log of the number of buckets.
The buckets.
methods
id (self)
init;
|
Designated initializer.
void
empty;
|
Remove all elements from the table.
void do Block block; |
Evaluate the block for each object element in this HashTable, by passing this method to the BucketElements.
Any at All key; |
Return the key if present, or nil otherwise.
Any member All object; |
A different name for at.
Any member All key equal selector cmp; |
Like member, but the elements are compared using the selector cmp.
Any memq All key; |
Like member, but the element is identified on reference equality.
void encodeUsingCoder Encoder coder; |
Undocumented.
void initWithCoder Decoder coder; |
Undocumented.
protected void adjust_length int inc pre inc != 0; |
Adjust the length of the hashtable, resizing if necessary.
protected void resize int new_shift; |
Undocumented.
void resizing_add BucketElement elt; |
Undocumented.
The HashTableContainer class is just a HashTable which knows how to mark its elements as a container. It is intended to be inherited by various class employing the HashTable class as a superclass for implementation reuse.
inherits
State supers: HashTable, Container
methods
void
gc_container_mark_elements;
|
Undocumented.
inherits
State supers: HashTableContainer, MutableKeyed
methods
void add BucketElement elt; |
Add elt to the receiving hashtable.
void remove BucketElement elt; |
Remove elt from the receiving hashtable, if present.
inherits
State supers: State, Enumerator
methods
instance (id) with Indexed b; |
Undocumented.
variables
The array the dictionary uses to store the buckets.
The next bucket index we shall use.
The bucket element we're looking at.
methods
protected id init Indexed b; |
Undocumented.
protected boolean
next;
|
Update elt to point to the next bucket element.