Home | History | Annotate | Download | only in cutils

Lines Matching refs:map

18  * Hash map.
31 /** A hash map. */
35 * Creates a new hash map. Returns NULL if memory allocation fails.
45 * Frees the hash map. Does not free the keys or values themselves.
47 void hashmapFree(Hashmap* map);
56 * Puts value for the given key in the map. Returns pre-existing value if
59 * If memory allocation fails, this function returns NULL, the map's size
62 void* hashmapPut(Hashmap* map, void* key, void* value);
65 * Gets a value from the map. Returns NULL if no entry for the given key is
68 void* hashmapGet(Hashmap* map, void* key);
71 * Returns true if the map contains an entry for the given key.
73 bool hashmapContainsKey(Hashmap* map, void* key);
82 void* hashmapMemoize(Hashmap* map, void* key,
86 * Removes an entry from the map. Returns the removed value or NULL if no
89 void* hashmapRemove(Hashmap* map, void* key);
92 * Gets the number of entries in this map.
94 size_t hashmapSize(Hashmap* map);
97 * Invokes the given callback on each entry in the map. Stops iterating if
100 void hashmapForEach(Hashmap* map,
109 * Locks the hash map so only the current thread can access it.
111 void hashmapLock(Hashmap* map);
114 * Unlocks the hash map so other threads can access it.
116 void hashmapUnlock(Hashmap* map);
139 size_t hashmapCurrentCapacity(Hashmap* map);
144 size_t hashmapCountCollisions(Hashmap* map);