MySQL 5.6.14 Source Code Document
|
Classes | |
struct | hash_ops |
Typedefs | |
typedef struct _genhash | genhash_t |
Enumerations | |
enum | update_type { MODIFICATION, NEW } |
Functions | |
MEMCACHED_PUBLIC_API genhash_t * | genhash_init (int est, struct hash_ops ops) |
MEMCACHED_PUBLIC_API void | genhash_free (genhash_t *h) |
MEMCACHED_PUBLIC_API void | genhash_store (genhash_t *h, const void *k, size_t klen, const void *v, size_t vlen) |
MEMCACHED_PUBLIC_API void * | genhash_find (genhash_t *h, const void *k, size_t klen) |
MEMCACHED_PUBLIC_API int | genhash_delete (genhash_t *h, const void *k, size_t klen) |
MEMCACHED_PUBLIC_API int | genhash_delete_all (genhash_t *h, const void *k, size_t klen) |
MEMCACHED_PUBLIC_API enum update_type | genhash_update (genhash_t *h, const void *k, size_t klen, const void *v, size_t vlen) |
MEMCACHED_PUBLIC_API enum update_type | genhash_fun_update (genhash_t *h, const void *key, size_t klen, void *(*upd)(const void *k, const void *oldv, size_t *ns, void *a), void(*fr)(void *), void *arg, const void *def, size_t deflen) |
MEMCACHED_PUBLIC_API void | genhash_iter (genhash_t *h, void(*iterfunc)(const void *key, size_t nkey, const void *val, size_t nval, void *arg), void *arg) |
MEMCACHED_PUBLIC_API void | genhash_iter_key (genhash_t *h, const void *key, size_t nkey, void(*iterfunc)(const void *key, size_t inkey, const void *val, size_t inval, void *arg), void *arg) |
MEMCACHED_PUBLIC_API int | genhash_size (genhash_t *h) |
MEMCACHED_PUBLIC_API int | genhash_clear (genhash_t *h) |
MEMCACHED_PUBLIC_API int | genhash_size_for_key (genhash_t *h, const void *k, size_t nkey) |
MEMCACHED_PUBLIC_API int | genhash_string_hash (const void *k, size_t nkey) |
enum update_type |
MEMCACHED_PUBLIC_API int genhash_clear | ( | genhash_t * | h | ) |
MEMCACHED_PUBLIC_API int genhash_delete | ( | genhash_t * | h, |
const void * | k, | ||
size_t | klen | ||
) |
MEMCACHED_PUBLIC_API int genhash_delete_all | ( | genhash_t * | h, |
const void * | k, | ||
size_t | klen | ||
) |
MEMCACHED_PUBLIC_API void* genhash_find | ( | genhash_t * | h, |
const void * | k, | ||
size_t | klen | ||
) |
MEMCACHED_PUBLIC_API void genhash_free | ( | genhash_t * | h | ) |
MEMCACHED_PUBLIC_API enum update_type genhash_fun_update | ( | genhash_t * | h, |
const void * | key, | ||
size_t | klen, | ||
void *(*)(const void *k, const void *oldv, size_t *ns, void *a) | upd, | ||
void(*)(void *) | fr, | ||
void * | arg, | ||
const void * | def, | ||
size_t | deflen | ||
) |
Create or update an item in-place with a function.
h | hashtable |
key | the key of the item |
upd | function that will be called with the key and current value. Should return the new value. |
fr | function to free the return value returned by the update function |
def | default value |
MEMCACHED_PUBLIC_API void genhash_iter | ( | genhash_t * | h, |
void(*)(const void *key, size_t nkey, const void *val, size_t nval, void *arg) | iterfunc, | ||
void * | arg | ||
) |
MEMCACHED_PUBLIC_API void genhash_iter_key | ( | genhash_t * | h, |
const void * | key, | ||
size_t | nkey, | ||
void(*)(const void *key, size_t inkey, const void *val, size_t inval, void *arg) | iterfunc, | ||
void * | arg | ||
) |
Iterate all values for a given key in a hash table.
h | the genhash |
key | the key to iterate |
iterfunc | a function that will be called once for every k/v pair |
arg | an argument to be passed to the iterfunc on each iteration |
MEMCACHED_PUBLIC_API int genhash_size | ( | genhash_t * | h | ) |
MEMCACHED_PUBLIC_API int genhash_size_for_key | ( | genhash_t * | h, |
const void * | k, | ||
size_t | nkey | ||
) |
MEMCACHED_PUBLIC_API void genhash_store | ( | genhash_t * | h, |
const void * | k, | ||
size_t | klen, | ||
const void * | v, | ||
size_t | vlen | ||
) |
MEMCACHED_PUBLIC_API int genhash_string_hash | ( | const void * | k, |
size_t | nkey | ||
) |
MEMCACHED_PUBLIC_API enum update_type genhash_update | ( | genhash_t * | h, |
const void * | k, | ||
size_t | klen, | ||
const void * | v, | ||
size_t | vlen | ||
) |