Reference Guide C API www.spreadconcepts.com


Programmer's Reference Guide
Replicated Hash Table
Version 2.0


Snapshot Operations

rht_snap_fini may be called once and only once on a snapshot successfully initialized by a call to rht_snapshot to reclaim resources associated with the snapshot. After calling rht_snap_fini on such a snapshot, it is only valid to subsequently use that rht_snap in a call to rht_snapshot.

rht_snap_size returns the size of the snapshot snap.

rht_snap_begin initializes the iterator pointed at by it to reference the first key-value pair in the snapshot snap, or if the snapshot is empty to reference the "end" key-value pair of the snapshot.

rht_snap_end initializes the iterator pointed at by it to reference the special "end" key-value pair of the snapshot snap. This sentinel value is one past the last valid key-value pair contained in the snapshot.

rht_snap_get_it performs a lookup of key on the snapshot snap. If an equivalent key exists in the snapshot, then the iterator pointed at by it will be initialized to reference the corresponding key-value pair. If no such key exists, then it will be initialized to reference the special "end" key-value pair of the snapshot.



Copyright © 2004, Spread Concepts LLC, All rights reserved