The interface implemented by applications to provide custom ordering of records. More...
Public Attributes | |
int(* | compare )(WT_COLLATOR *collator, WT_SESSION *session, const WT_ITEM *key1, const WT_ITEM *key2, int *cmp) |
Callback to compare keys. | |
The interface implemented by applications to provide custom ordering of records.
Applications register their implementation with WiredTiger by calling WT_CONNECTION::add_collator.
int(* WT_COLLATOR::compare)(WT_COLLATOR *collator, WT_SESSION *session, const WT_ITEM *key1, const WT_ITEM *key2, int *cmp) |
Callback to compare keys.
[out] | cmp | set to -1 if key1 < key2 , 0 if key1 == key2 , 1 if key1 > key2 . |