48#define SCDB_MAX_KEY_LENGTH 1024
50#define SCDB_MAX_VALUE_LENGTH 4096
88 char* value_buffer,
size_t* value_buffer_length);
104 const char* value_buffer,
size_t value_length);
141 const char* current_value,
size_t current_value_length,
142 const char* new_value,
size_t new_value_length);
157 const char* key,
size_t key_length);
188 char* key_buffer,
size_t* key_buffer_length,
189 char* value_buffer,
size_t* value_buffer_length);
scdb_index * scdb_open(size_t max_disk_bytes, const char *disk_path)
Opens an existing index, or creates one if it does not exist.
Definition nullimplementation.c:13
scdb_iterator * scdb_iterate(scdb_index *index, const char *key, size_t key_length)
Create an iterator over the index, starting at the smallest key that is greater than or equal to the ...
Definition nullimplementation.c:40
scdb_status
Status code return by SCDB function calls.
Definition scdb.h:32
@ SCDB_ERROR
Some other error occurred.
Definition scdb.h:44
@ SCDB_OK
Operation completed successfully.
Definition scdb.h:34
@ SCDB_VALUE_BUFFER_TOO_SMALL
The buffer provided for the value is too small.
Definition scdb.h:40
@ SCDB_KEY_BUFFER_TOO_SMALL
The buffer provided for the key is too small.
Definition scdb.h:38
@ SCDB_NOT_FOUND
The specified key was not found so the operation was not perfomed.
Definition scdb.h:36
@ SCDB_COMPARE_FAILED
For compare and swap, the current value did not match.
Definition scdb.h:42
scdb_status scdb_delete(scdb_index *index, const char *key, size_t key_length)
Removes the specified key and associated value from the index.
Definition nullimplementation.c:30
scdb_status scdb_write(scdb_index *index, const char *key, size_t key_length, const char *value_buffer, size_t value_length)
Sets the specified key to map to the specified value.
Definition nullimplementation.c:25
scdb_status scdb_next(scdb_iterator *iterator, char *key_buffer, size_t *key_buffer_length, char *value_buffer, size_t *value_buffer_length)
Reads the current key/value pair from the iterator, then advances the iterator.
Definition nullimplementation.c:48
scdb_status scdb_read(scdb_index *index, const char *key, size_t key_length, char *value_buffer, size_t *value_buffer_length)
Reads the value corresponding to the specified key (exact match).
Definition nullimplementation.c:20
scdb_status scdb_cas(scdb_index *index, const char *key, size_t key_length, const char *current_value, size_t current_value_length, const char *new_value, size_t new_value_length)
Performs an atomic compare and swap.
Definition nullimplementation.c:34
void scdb_iterator_close(scdb_iterator *iterator)
Closes an open iterator.
Definition nullimplementation.c:45
void scdb_close(scdb_index *index)
Closes an open index.
Definition nullimplementation.c:17
Definition refimplementation.c:24
Definition refimplementation.c:38