|
ATLAS Offline Software
|
Go to the documentation of this file.
45 #ifndef ALGORITHM_HASH_TABLE_H
46 #define ALGORITHM_HASH_TABLE_H
96 #define HASH_TABLE_NULL ((void *) 0)
JetConstituentVector::iterator iterator
HashTableValue hash_table_iter_next(HashTableIterator *iterator)
Using a hash table iterator, retrieve the next key.
void * HashTableKey
A key to look up a value in a HashTable.
struct _HashTable HashTable
A hash table structure.
void(* HashTableKeyFreeFunc)(HashTableKey value)
Type of function used to free keys when entries are removed from a hash table.
Definition of a HashTableIterator.
struct _HashTableEntry HashTableEntry
Internal structure representing an entry in a hash table.
int hash_table_insert(HashTable *hash_table, HashTableKey key, HashTableValue value)
Insert a value into a hash table, overwriting any existing entry using the same key.
void hash_table_free(HashTable *hash_table)
Destroy a hash table.
void hash_table_iterate(HashTable *hash_table, HashTableIterator *iter)
Initialise a HashTableIterator to iterate over a hash table.
void(* HashTableValueFreeFunc)(HashTableValue value)
Type of function used to free values when entries are removed from a hash table.
void hash_table_register_free_functions(HashTable *hash_table, HashTableKeyFreeFunc key_free_func, HashTableValueFreeFunc value_free_func)
Register functions used to free the key and value when an entry is removed from a hash table.
HashTableEntry * next_entry
int hash_table_num_entries(HashTable *hash_table)
Retrieve the number of entries in a hash table.
int hash_table_remove(HashTable *hash_table, HashTableKey key)
Remove a value from a hash table.
HashTable * hash_table_new(HashTableHashFunc hash_func, HashTableEqualFunc equal_func)
Create a new hash table.
int hash_table_iter_has_more(HashTableIterator *iterator)
Determine if there are more keys in the hash table to iterate over.
int(* HashTableEqualFunc)(HashTableKey value1, HashTableKey value2)
Function used to compare two keys for equality.
unsigned long(* HashTableHashFunc)(HashTableKey value)
Hash function used to generate hash values for keys used in a hash table.
HashTableValue hash_table_lookup(HashTable *hash_table, HashTableKey key)
Look up a value in a hash table by key.
void * HashTableValue
A value stored in a HashTable.