D-Bus 1.15.12
|
Internals of DBusHashTable. More...
Data Fields | |
int | refcount |
Reference count. | |
DBusHashEntry ** | buckets |
Pointer to bucket array. | |
DBusHashEntry * | static_buckets [DBUS_SMALL_HASH_TABLE] |
Bucket array used for small tables (to avoid mallocs and frees). | |
int | n_buckets |
Total number of buckets allocated at **buckets. | |
int | n_entries |
Total number of entries present in table. | |
int | hi_rebuild_size |
Enlarge table when n_entries gets to be this large. | |
int | lo_rebuild_size |
Shrink table when n_entries gets below this. | |
int | down_shift |
Shift count used in hashing function. | |
int | mask |
Mask value used in hashing function. | |
DBusHashType | key_type |
Type of keys used in this table. | |
DBusFindEntryFunction | find_function |
Function for finding entries. | |
DBusFreeFunction | free_key_function |
Function to free keys. | |
DBusFreeFunction | free_value_function |
Function to free values. | |
DBusMemPool * | entry_pool |
Memory pool for hash entries. | |
Internals of DBusHashTable.
Hash table internals. Hash tables are opaque objects, they must be used via accessor functions.
Definition at line 175 of file dbus-hash.c.
DBusHashEntry** DBusHashTable::buckets |
Pointer to bucket array.
Each element points to first entry in bucket's hash chain, or NULL.
Definition at line 178 of file dbus-hash.c.
Referenced by _dbus_hash_iter_lookup(), _dbus_hash_iter_next(), _dbus_hash_table_new(), and _dbus_hash_table_unref().
int DBusHashTable::down_shift |
Shift count used in hashing function.
Designed to use high- order bits of randomized keys.
Definition at line 198 of file dbus-hash.c.
Referenced by _dbus_hash_table_new().
DBusMemPool* DBusHashTable::entry_pool |
Memory pool for hash entries.
Definition at line 213 of file dbus-hash.c.
Referenced by _dbus_hash_table_free_preallocated_entry(), _dbus_hash_table_new(), and _dbus_hash_table_unref().
DBusFindEntryFunction DBusHashTable::find_function |
Function for finding entries.
Definition at line 208 of file dbus-hash.c.
Referenced by _dbus_hash_iter_lookup(), _dbus_hash_table_insert_int(), _dbus_hash_table_insert_string_preallocated(), _dbus_hash_table_insert_uintptr(), _dbus_hash_table_lookup_int(), _dbus_hash_table_lookup_string(), _dbus_hash_table_lookup_uintptr(), _dbus_hash_table_new(), _dbus_hash_table_remove_int(), _dbus_hash_table_remove_string(), and _dbus_hash_table_remove_uintptr().
DBusFreeFunction DBusHashTable::free_key_function |
Function to free keys.
Definition at line 210 of file dbus-hash.c.
Referenced by _dbus_hash_iter_lookup(), _dbus_hash_table_insert_int(), _dbus_hash_table_insert_string_preallocated(), _dbus_hash_table_insert_uintptr(), and _dbus_hash_table_new().
DBusFreeFunction DBusHashTable::free_value_function |
Function to free values.
Definition at line 211 of file dbus-hash.c.
Referenced by _dbus_hash_iter_set_value(), _dbus_hash_table_insert_int(), _dbus_hash_table_insert_string_preallocated(), _dbus_hash_table_insert_uintptr(), and _dbus_hash_table_new().
int DBusHashTable::hi_rebuild_size |
Enlarge table when n_entries gets to be this large.
Definition at line 192 of file dbus-hash.c.
Referenced by _dbus_hash_table_new().
DBusHashType DBusHashTable::key_type |
Type of keys used in this table.
Definition at line 205 of file dbus-hash.c.
Referenced by _dbus_hash_table_insert_int(), _dbus_hash_table_insert_string(), _dbus_hash_table_insert_string_preallocated(), _dbus_hash_table_insert_uintptr(), _dbus_hash_table_lookup_int(), _dbus_hash_table_lookup_string(), _dbus_hash_table_lookup_uintptr(), _dbus_hash_table_new(), _dbus_hash_table_remove_int(), _dbus_hash_table_remove_string(), and _dbus_hash_table_remove_uintptr().
int DBusHashTable::lo_rebuild_size |
Shrink table when n_entries gets below this.
Definition at line 195 of file dbus-hash.c.
Referenced by _dbus_hash_table_new().
int DBusHashTable::mask |
Mask value used in hashing function.
Definition at line 202 of file dbus-hash.c.
Referenced by _dbus_hash_table_new().
int DBusHashTable::n_buckets |
Total number of buckets allocated at **buckets.
Definition at line 186 of file dbus-hash.c.
Referenced by _dbus_hash_iter_lookup(), _dbus_hash_iter_next(), _dbus_hash_table_new(), and _dbus_hash_table_unref().
int DBusHashTable::n_entries |
Total number of entries present in table.
Definition at line 189 of file dbus-hash.c.
Referenced by _dbus_hash_iter_init(), _dbus_hash_iter_lookup(), _dbus_hash_iter_next(), _dbus_hash_table_get_n_entries(), and _dbus_hash_table_new().
int DBusHashTable::refcount |
Reference count.
Definition at line 176 of file dbus-hash.c.
Referenced by _dbus_hash_table_new(), _dbus_hash_table_ref(), and _dbus_hash_table_unref().
DBusHashEntry* DBusHashTable::static_buckets[DBUS_SMALL_HASH_TABLE] |
Bucket array used for small tables (to avoid mallocs and frees).
Definition at line 182 of file dbus-hash.c.
Referenced by _dbus_hash_table_new(), and _dbus_hash_table_unref().