Coconut Framework
beta
|
Define CNHashTable data structure. More...
Go to the source code of this file.
Classes | |
struct | CNHashTableMethods |
Set of methods for item in CNHashTable These functions are called in CNHashTable. More... | |
struct | CNHashTable |
Hash table for any data. More... | |
Macros | |
#define | CNArraySizeOfHashTable 256 |
Array size of CNHashTable. | |
Typedefs | |
typedef uint64_t(* | CNCalcHashItemFuncRef )(const void *obj, void *info) |
Function to calc hash value of item in CNHashTable. | |
Functions | |
void | CNInitHashTable (struct CNHashTable *dst, const struct CNHashTableMethods *methods, struct CNResource *resource) |
Initialize CNHashTable. More... | |
void | CNDestroyHashTable (struct CNHashTable *dst, void *info) |
Destroy all contexts in CNHashTable. More... | |
const void * | CNSearchHashTable (const struct CNHashTable *table, const void *src, void *info) |
Search item in CNHashTable. More... | |
const void * | CNAddToHashTable (struct CNHashTable *table, const void *src, void *info) |
Add item to CNHashTable. More... | |
Define CNHashTable data structure.
void CNInitHashTable | ( | struct CNHashTable * | dst, |
const struct CNHashTableMethods * | methods, | ||
struct CNResource * | resource | ||
) |
Initialize CNHashTable.
dst | Destination hash table |
methods | Methods to operate hash items |
resource | Resource for hash table |
void CNDestroyHashTable | ( | struct CNHashTable * | dst, |
void * | info | ||
) |
Destroy all contexts in CNHashTable.
dst | Destination hash table |
info | User defined info |
const void* CNSearchHashTable | ( | const struct CNHashTable * | table, |
const void * | src, | ||
void * | info | ||
) |
Search item in CNHashTable.
obj | Matched object |
NULL | There are no matched object |
table | Hash table |
src | Source data to search |
info | User defined info |
const void* CNAddToHashTable | ( | struct CNHashTable * | table, |
const void * | src, | ||
void * | info | ||
) |
Add item to CNHashTable.
table | Destination table |
src | Source item |
info | User defined info |