FreeSWITCH API Documentation
1.7.0
|
Go to the source code of this file.
Variables | |
static const unsigned int | primes [] |
const unsigned int | prime_table_length = sizeof(primes)/sizeof(primes[0]) |
const float | max_load_factor = 0.65f |
|
static |
Definition at line 156 of file switch_hashtable.c.
References entry::destructor, switch_hashtable::entrycount, switch_hashtable::eqfn, entry::flags, freekey, entry::h, HASHTABLE_FLAG_FREE_KEY, HASHTABLE_FLAG_FREE_VALUE, entry::k, entry::next, switch_safe_free, switch_hashtable::table, and entry::v.
Referenced by switch_hashtable_insert_destructor(), and switch_hashtable_remove().
|
static |
Definition at line 94 of file switch_hashtable.c.
References entry::h, indexFor(), switch_hashtable::loadlimit, memset(), entry::next, prime_table_length, switch_hashtable::primeindex, primes, switch_safe_free, switch_hashtable::table, and switch_hashtable::tablelength.
Referenced by switch_hashtable_insert_destructor().
switch_status_t switch_create_hashtable | ( | switch_hashtable_t ** | hp, |
unsigned int | minsize, | ||
unsigned int(*)(void *) | hashf, | ||
int(*)(void *, void *) | eqf | ||
) |
Definition at line 56 of file switch_hashtable.c.
References switch_hashtable::entrycount, switch_hashtable::eqfn, entry::h, switch_hashtable::hashfn, switch_hashtable::loadlimit, memset(), prime_table_length, switch_hashtable::primeindex, primes, SWITCH_STATUS_FALSE, SWITCH_STATUS_SUCCESS, switch_hashtable::table, and switch_hashtable::tablelength.
Referenced by switch_core_hash_init_case(), and switch_core_inthash_init().
unsigned int switch_hashtable_count | ( | switch_hashtable_t * | h | ) |
Definition at line 151 of file switch_hashtable.c.
void switch_hashtable_destroy | ( | switch_hashtable_t ** | h | ) |
Definition at line 253 of file switch_hashtable.c.
References entry::destructor, entry::flags, freekey, HASHTABLE_FLAG_FREE_KEY, HASHTABLE_FLAG_FREE_VALUE, entry::k, entry::next, switch_safe_free, and entry::v.
Referenced by switch_core_hash_destroy(), and switch_core_inthash_destroy().
switch_hashtable_iterator_t* switch_hashtable_first_iter | ( | switch_hashtable_t * | h, |
switch_hashtable_iterator_t * | it | ||
) |
Definition at line 316 of file switch_hashtable.c.
References switch_hashtable_iterator::e, entry::h, switch_hashtable_iterator::h, switch_hashtable_iterator::pos, switch_assert, switch_hashtable_next(), and switch_zmalloc.
Referenced by switch_core_hash_first_iter().
int switch_hashtable_insert_destructor | ( | switch_hashtable_t * | h, |
void * | k, | ||
void * | v, | ||
hashtable_flag_t | flags, | ||
hashtable_destructor_t | destructor | ||
) |
Definition at line 194 of file switch_hashtable.c.
References _switch_hashtable_remove(), entry::destructor, entry::flags, entry::h, hash, HASHTABLE_DUP_CHECK, hashtable_expand(), indexFor(), entry::k, entry::next, and entry::v.
Referenced by switch_core_hash_insert_destructor(), and switch_core_inthash_insert().
switch_hashtable_iterator_t* switch_hashtable_next | ( | switch_hashtable_iterator_t ** | iP | ) |
Definition at line 283 of file switch_hashtable.c.
References switch_hashtable_iterator::e, switch_hashtable_iterator::h, entry::next, switch_hashtable_iterator::pos, switch_hashtable::table, and switch_hashtable::tablelength.
Referenced by switch_core_hash_next(), and switch_hashtable_first_iter().
void* switch_hashtable_remove | ( | switch_hashtable_t * | h, |
void * | k | ||
) |
Definition at line 244 of file switch_hashtable.c.
References _switch_hashtable_remove(), hash, and indexFor().
Referenced by switch_core_hash_delete(), and switch_core_inthash_delete().
void* switch_hashtable_search | ( | switch_hashtable_t * | h, |
void * | k | ||
) |
Definition at line 227 of file switch_hashtable.c.
References entry::h, hash, indexFor(), entry::k, entry::next, and entry::v.
Referenced by switch_core_hash_find(), and switch_core_inthash_find().
void switch_hashtable_this | ( | switch_hashtable_iterator_t * | i, |
const void ** | key, | ||
switch_ssize_t * | klen, | ||
void ** | val | ||
) |
void switch_hashtable_this_val | ( | switch_hashtable_iterator_t * | i, |
void * | val | ||
) |
const float max_load_factor = 0.65f |
Definition at line 52 of file switch_hashtable.c.
Definition at line 51 of file switch_hashtable.c.
Referenced by hashtable_expand(), and switch_create_hashtable().
|
static |
Definition at line 42 of file switch_hashtable.c.
Referenced by hashtable_expand(), and switch_create_hashtable().