22 typedef void (*hash_cache_cleanup_t) (
void *value);
24 struct hash_cache *hash_cache_create(
int size,
hash_func_t func, hash_cache_cleanup_t cleanup);
25 void hash_cache_delete(
struct hash_cache *cache);
27 int hash_cache_insert(
struct hash_cache *cache,
const char *key,
void *value,
int lifetime);
28 void *hash_cache_remove(
struct hash_cache *cache,
const char *key);
29 void *hash_cache_lookup(
struct hash_cache *cache,
const char *key);
31 void hash_cache_firstkey(
struct hash_cache *cache);
32 int hash_cache_nextkey(
struct hash_cache *cache,
char **key,
void **item);
unsigned(* hash_func_t)(const char *key)
The type signature for a hash function given to hash_table_create.
Definition: hash_table.h:42
A general purpose hash table.