Lines Matching defs:value
48 void *value;
86 * - HASHMAP_ADD - only add key/value if key doesn't exist yet;
87 * - HASHMAP_SET - add key/value pair if key doesn't exist yet; otherwise,
88 * update value;
89 * - HASHMAP_UPDATE - update value, if key already exists; otherwise, do
91 * - HASHMAP_APPEND - always add key/value pair, even if key already exists.
95 * used, it will return last inserted key/value entry (first in a bucket
106 * hashmap__insert() adds key/value entry w/ various semantics, depending on
107 * provided strategy value. If a given key/value pair replaced already
108 * existing key/value pair, both old key and old value will be returned
112 int hashmap__insert(struct hashmap *map, const void *key, void *value,
117 const void *key, void *value)
119 return hashmap__insert(map, key, value, HASHMAP_ADD, NULL, NULL);
123 const void *key, void *value,
126 return hashmap__insert(map, key, value, HASHMAP_SET,
131 const void *key, void *value,
134 return hashmap__insert(map, key, value, HASHMAP_UPDATE,
139 const void *key, void *value)
141 return hashmap__insert(map, key, value, HASHMAP_APPEND, NULL, NULL);
147 bool hashmap__find(const struct hashmap *map, const void *key, void **value);