libaaruformat 1.0
Aaru Data Preservation Suite - Format Library
Loading...
Searching...
No Matches
kv_pair_t Struct Reference

Single key/value slot used internally by the open-addressing hash map. More...

#include <aaruformat/hash_map.h>

Data Fields

uint64_t key
 Stored key (64-bit). May use a reserved sentinel to denote an empty slot.
uint64_t value
 Associated value payload (64-bit) stored alongside the key.

Detailed Description

Single key/value slot used internally by the open-addressing hash map.

Collision resolution strategy (implementation detail): linear or quadratic probing (see source). An empty slot is typically represented by a key sentinel (e.g. 0 or another reserved value) – callers never interact with individual kv_pair_t entries directly; they are managed through the map API.

Definition at line 32 of file hash_map.h.

Field Documentation

◆ key

uint64_t kv_pair_t::key

Stored key (64-bit). May use a reserved sentinel to denote an empty slot.

Definition at line 34 of file hash_map.h.

Referenced by insert_map(), lookup_map(), and resize_map().

◆ value

uint64_t kv_pair_t::value

Associated value payload (64-bit) stored alongside the key.

Definition at line 35 of file hash_map.h.

Referenced by insert_map(), and lookup_map().


The documentation for this struct was generated from the following file: