GATE
|
A flat map stores an array of key/value pair, the key needs to be unique. More...
#include <maps.h>
A flat map stores an array of key/value pair, the key needs to be unique.
This map type preserves the order in which items were added at its end. Key searchs have complexity of "O(n)".
gate_comparer_t key_comparer |
Pointer to comparer function to search for keys
gate_size_t key_size |
Size of key element
gate_mem_copyctor_t key_constructor |
Constructor function of key elements
gate_mem_dtor_t key_destructor |
Destructor function of key elements
gate_size_t value_size |
Size of value element
gate_mem_copyctor_t value_constructor |
Constructor function of value elements
gate_mem_dtor_t value_destructor |
Destructor function of value elements
gate_size_t item_count |
currently used content pointers
gate_size_t item_capacity |
amount of allocated content pointers
gate_size_t item_size |
total size of item (mapping-header + key + value)
gate_size_t item_key_offset |
offset of key content within item block
gate_size_t item_value_offset |
offset of value content within item block
gate_mapping_t** items |
array of pointers to entries (containing key/value)