roo_collections
API Documentation for roo_collections
Loading...
Searching...
No Matches
flat_small_hash_set.h
Go to the documentation of this file.
1
#pragma once
2
3
/// @file
4
/// @brief Flat, memory-conscious hash set aliases.
5
/// @ingroup roo_collections
6
7
#include <functional>
8
9
#include "
roo_collections/flat_small_hashtable.h
"
10
11
namespace
roo_collections
{
12
13
/// @brief Flat, memory-conscious hash set optimized for small collections.
14
///
15
/// Stores keys in a single backing array and provides average constant-time
16
/// lookup/insert/erase.
17
///
18
/// @tparam Key Stored key type.
19
/// @tparam HashFn Hash function type.
20
/// @tparam KeyCmpFn Equality predicate type.
21
template
<
typename
Key,
typename
HashFn = DefaultHashFn<Key>,
22
typename
KeyCmpFn = std::equal_to<Key>>
23
using
FlatSmallHashSet
=
24
FlatSmallHashtable<Key, Key, HashFn, DefaultKeyFn<Key>
, KeyCmpFn>;
25
26
/// @brief String-specialized flat hash set with heterogeneous lookup support.
27
///
28
/// Accepts `std::string`, `const char*`, `roo::string_view`, and Arduino
29
/// `String` (when available) for lookup operations.
30
using
FlatSmallStringHashSet
=
31
FlatSmallHashtable
<std::string, std::string,
TransparentStringHashFn
,
32
TransparentEq
,
DefaultKeyFn<std::string>
>;
33
34
}
// namespace roo_collections
roo_collections::FlatSmallHashtable
Flat, memory-conscious hash table optimized for small collections.
Definition
flat_small_hashtable.h:182
flat_small_hashtable.h
Flat, memory-conscious hash table implementation.
roo_collections
Definition
roo_collections.h:10
roo_collections::DefaultKeyFn
Definition
flat_small_hashtable.h:164
roo_collections::TransparentEq
Definition
flat_small_hashtable.h:139
roo_collections::TransparentStringHashFn
Definition
flat_small_hashtable.h:111
temp_repos
roo_collections
src
roo_collections
flat_small_hash_set.h
Generated by
1.9.8