[Next] [Previous] [Up] [Top] [Contents] [Index]

8 Collections

Collection Keys

All collections in Dylan are keyed. That is, all collections can be viewed abstractly as partial functions that map keys to elements. (This choice precludes pure sets from being considered collections, although it is straightforward simply to ignore the keys for a collection and consider it simply as a set of elements.) The element function implements this partial mapping of keys to elements.

Every collection has a key test, which is the test used for determining whether a given key matches a key in the collection. The key test of a collection can be accessed using the key-test function.


Dylan Reference Manual - 17 OCT 1995
[Next] [Previous] [Up] [Top] [Contents] [Index]

Generated with Harlequin WebMaker