51 for (i = 0; i <
LOOP; i++) {
68 for (i = 0; i <
LOOP; i++) {
72 record = db.
find(&key);
76 std::cerr <<
"db::find() ok, but returned bad value" << std::endl;
91 for (i = 0; i <
LOOP; i++) {
102 for (i = 0; i <
LOOP; i++) {
107 record = db.
find(&key);
111 std::cerr <<
"db::find() returned error " << e.
get_string()
123 std::cout <<
"success!" << std::endl;
134 std::cerr <<
"run_demo() failed with unexpected error "
void create(const char *filename, uint32_t flags=0, uint32_t mode=0644, const ups_parameter_t *param=0)
void set_size(uint32_t size)
void erase(key *k, uint32_t flags=0)
ups_status_t get_errno() const
db create_db(uint16_t name, uint32_t flags=0, const ups_parameter_t *param=0)
#define UPS_PARAM_RECORD_SIZE
void close(uint32_t flags=0)
void insert(txn *t, key *k, record *r, uint32_t flags=0)
int main(int argc, char **argv)
const char * get_string() const
void set_size(uint16_t size)
void set_data(void *data)
record find(txn *t, key *k, uint32_t flags=0)
void close(uint32_t flags=0)
void open(const char *filename, uint32_t flags=0, const ups_parameter_t *param=0)
db open_db(uint16_t name, uint32_t flags=0, const ups_parameter_t *param=0)
void set_data(void *data)
#define UPS_PARAM_KEY_TYPE
#define UPS_KEY_NOT_FOUND