HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions
v1::wfree_unordered_map< K, V, MAX_NR_ITEMS > Class Template Reference

#include <hikogui/wfree_unordered_map.hpp>

Public Types

using key_type = K
 
using mapped_type = V
 

Public Member Functions

constexpr wfree_unordered_map (wfree_unordered_map const &) noexcept=delete
 
constexpr wfree_unordered_map (wfree_unordered_map &&) noexcept=delete
 
constexpr wfree_unordered_mapoperator= (wfree_unordered_map const &) noexcept=delete
 
constexpr wfree_unordered_mapoperator= (wfree_unordered_map &&) noexcept=delete
 
void insert (K key, V value) noexcept
 
std::vector< K > keys () const noexcept
 
V & operator[] (K const &key) noexcept
 
std::optional< V > get (K const &key) const noexcept
 
get (K const &key, V const &default_value) const noexcept
 
std::optional< V > erase (K const &key) noexcept
 

Static Public Member Functions

static std::size_t make_hash (K const &key) noexcept
 

Detailed Description

template<typename K, typename V, std::size_t MAX_NR_ITEMS>
class v1::wfree_unordered_map< K, V, MAX_NR_ITEMS >

Unordered map with wait-free insert, get and erase.

This class can be instantiated as a global variable without needing initialization.


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