88 size_t itemsize, |
88 size_t itemsize, |
89 size_t buckets |
89 size_t buckets |
90 ); |
90 ); |
91 |
91 |
92 /** |
92 /** |
|
93 * Creates a new hash map with a default number of buckets. |
|
94 * |
|
95 * If \p item_size is CX_STORE_POINTERS, the created map will be created as if |
|
96 * cxMapStorePointers() was called immediately after creation. |
|
97 * |
|
98 * @note Iterators provided by this hash map implementation provide the remove operation. |
|
99 * The index value of an iterator is the incremented when the iterator advanced without removal. |
|
100 * In other words, when the iterator is finished, \c index==size . |
|
101 * |
|
102 * @param itemsize the size of one element |
|
103 * @return a pointer to the new hash map |
|
104 */ |
|
105 #define cxHashMapCreateSimple(itemsize) \ |
|
106 cxHashMapCreate(cxDefaultAllocator, itemsize, 0) |
|
107 |
|
108 /** |
93 * Increases the number of buckets, if necessary. |
109 * Increases the number of buckets, if necessary. |
94 * |
110 * |
95 * The load threshold is \c 0.75*buckets. If the element count exceeds the load |
111 * The load threshold is \c 0.75*buckets. If the element count exceeds the load |
96 * threshold, the map will be rehashed. Otherwise, no action is performed and |
112 * threshold, the map will be rehashed. Otherwise, no action is performed and |
97 * this function simply returns 0. |
113 * this function simply returns 0. |