built-in shelf
OmniMark provides a method of working with all the referents defined in a system by treating them as if they belonged to a shelf called referents. Most of the operations that are available to programmer-defined shelves are available for the referents shelf.
referents
behaves like a programmer-defined shelf in that:
[...]
or {...}
operators,
repeat over
or using
.
The referents shelf is different than programmer-defined shelves in that:
new
cannot be used to insert a new item on the referents shelf. New referents are created with set referent
, or open...as referent
.
remove
cannot be used to insert or remove items on the referents shelf. Referents can be removed by attaching the referent to a stream with reopen
, and then discarding the stream.
Various types of operations can be explicitly performed on the referents shelf. These include:
referents {...}
)
referents has key
test)
key of referents [...]
)
number of referents
)
referents is attached
or this referent is attached
test)
repeat over referents
)
referents
shelf (using using referents
)