Next: , Previous: DSR Persistent Objects and Slot Access, Up: Data Store API Reference

8.4 Collections

To support collections, the data store must subclass the following classes.

— Class: elephant:persistent-collection

Class precedence list: persistent-collection, persistent, standard-object, t

Abstract superclass of all collection types.

— Class: elephant:btree

Class precedence list: btree, persistent-collection, persistent, standard-object, t

A hash-table like interface to a BTree, which stores things in a semi-ordered fashion.

— Class: elephant:btree-index

Class precedence list: btree-index, btree, persistent-collection, persistent-object, persistent, standard-object, t

Secondary index to an indexed-btree.

— Class: elephant:indexed-btree

Class precedence list: indexed-btree, btree, persistent-collection, persistent, standard-object, t

A BTree which supports secondary indices.

To create the data store-appropriate type of btree, the data store implements this method (and possibly related methods) aginst their store-controller.

— Generic Function: elephant-data-store:build-btree sc

Construct a btree of the appropriate type corresponding to this store-controller.

Most of the user-visible operations over BTrees must be implemented. Class indexing functions such as map-class and get-instances-by-value and related functions are all implemented using map-btree and map-index.

Mapping over the indices of a btree is important to derived facilities such as class indexing and the query subsystem.

— Generic Function: elephant:map-indices fn bt

Calls a two input function with the name and btree-index object of all secondary indices in the btree