Denys Duchier
This module provides functional interface for dictionaries
The module exports the following constructors:
{Dictionary.new ?D}
D
{Dictionary.newFromRecord +R ?D}
D initialized
using the key/value mapping provided by record R
Each functional dictionary instance D has the following
features:
{D.get +Key ?Value}
Value for the given Key,
or raises an exception if none
{D.put +Key +Value}
Value for the given Key
{D.condGet +Key +Default ?Value}
Value for the given Key, or
the Default if none
{D.reset}
{D.keys ?L}
L of all keys in D
{D.items ?L}
L of all values in D
{D.entries ?L}
L of all pairs Key#Values
for entries in D
{D.isEmpty ?B}
D is empty
{D.remove +Key}
Key if any
{D.member +Key ?B}
Key
{D.clone ?D2}
D2
that is a clone of D
{D.toRecord ?R}
D in the form of
a record R