Back: WeakValueIdentityDictionary
Up: Class reference
Forward: WeakValueLookupTable-hacks
 
Top: GNU Smalltalk User's Guide
Contents: Table of Contents
Index: Class index
About: About this document

6.180 WeakValueLookupTable

Defined in namespace Smalltalk
Category: Collections-Weak

I am similar to a plain LookupTable, but my values are stored in a weak array; I track which of the values are garbage collected and, as soon as one of them is accessed, I swiftly remove the associations for the garbage collected values

6.180.1 WeakValueLookupTable: hacks  (instance)
6.180.2 WeakValueLookupTable: rehashing  (instance)


6.180.1 WeakValueLookupTable: hacks

at: key ifAbsent: aBlock
Answer the value associated to the given key, or the result of evaluating aBlock if the key is not found

at: key ifPresent: aBlock
If aKey is absent, answer nil. Else, evaluate aBlock passing the associated value and answer the result of the invocation

includesKey: key
Answer whether the receiver contains the given key.


6.180.2 WeakValueLookupTable: rehashing

rehash
Rehash the receiver




This document was generated on May, 12 2002 using texi2html