diff options
author | gumi <git@gumi.ca> | 2018-03-14 13:24:32 -0400 |
---|---|---|
committer | gumi <git@gumi.ca> | 2018-03-14 14:03:32 -0400 |
commit | 5e986aba7502612ff837b1e215c3467622606f00 (patch) | |
tree | 910aa0f89db59d037f42fd54d23016381c5596f7 /src/emap/judyarray.h | |
parent | c3262df069c597bd3c56e167cadc077c077d0096 (diff) | |
download | plugin-5e986aba7502612ff837b1e215c3467622606f00.tar.gz plugin-5e986aba7502612ff837b1e215c3467622606f00.tar.bz2 plugin-5e986aba7502612ff837b1e215c3467622606f00.tar.xz plugin-5e986aba7502612ff837b1e215c3467622606f00.zip |
add judy array supportjudy
Diffstat (limited to 'src/emap/judyarray.h')
-rw-r--r-- | src/emap/judyarray.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/emap/judyarray.h b/src/emap/judyarray.h new file mode 100644 index 0000000..ad9e1f0 --- /dev/null +++ b/src/emap/judyarray.h @@ -0,0 +1,29 @@ +// Copyright (c) Copyright (c) Hercules Dev Team, licensed under GNU GPL. +// Copyright (c) 2018 Evol developers + +#ifndef EVOL_JUDY_ARRAY +#define EVOL_JUDY_ARRAY + +#include "common/hercules.h" +#include "common/db.h" + +struct judy_interface +{ + int64 last_id; + void *arrays; + int64 (*new_array) (void); + bool (*clear_array) (int64 id); + bool (*destroy_array) (int64 id); + bool (*array_exists) (int64 id); + int64 (*array_size) (int64 id); + const struct DBData* (*getvalue) (int64 id, const char *key, const struct DBData *defval); + bool (*setvalue) (int64 id, const char *key, struct DBData *value); +}; + +void judy_defaults(void); +void judy_init(void); +void judy_final(void); + +HPShared struct judy_interface *judy; + +#endif // EVOL_JUDY_ARRAY |