|
Defines |
| #define | make_trie() (aw_trie_t *)aw_malloc(sizeof(aw_trie_t)) |
| #define | OHT_DEFAULT_MODMASK 1 /* implies initialsize == 2 */ |
Functions |
| void | aw_trie_clear (aw_trie_t *trie) |
| | Leave the nodes, clear the buckets.
|
| void * | aw_trie_delete (const byte_t *s, aw_trie_t *trie) |
| | Remove a value associated with string from a trie - Returns:
- Return the pointer in the bin.
|
| void | aw_trie_destroy (aw_trie_t *trie) |
| | Free memory used by trie.
|
| void * | aw_trie_fetch (const byte_t *s, const aw_trie_t *trie) |
| int32_t | aw_trie_insert (const byte_t *s, void *value_ptr, aw_trie_t *trie) |
| | Insert a string into a trie with a pointer to an associated value. - Returns:
- Returns 0 on success, on error: -AW_OUTOFMEMORY_ERROR.
|
| aw_trie_t * | aw_trie_make (void) |
| | Constructor for a trie dictionary structure - Returns:
- Returns a pointer to a trie structure.
|
| void | aw_trie_thin (aw_trie_t *trie, void *user_ptr, u_int32_t(*eval)(void *user_ptr, void *value_ptr)) |
| | Free the memory for those nodes that eval( user_ptr, value_ptr ) returns non-zero . Can be used to map all elements.
|
| int32_t | aw_trie_uincr (const byte_t *s, u_int32_t uincr, aw_trie_t *trie) |
| | Interpret the user pointer as a 32bit unsigned int and increment by 'incr' . - Returns:
- Return 0 on success , non-0 on failure.
|