maomao90's Library
A C++20 library for competitive programming.
Loading...
Searching...
No Matches
maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG > Struct Template Reference

#include <hashmap.hpp>

Public Member Functions

constexpr T & operator[] (const K &k)
 
constexpr bool erase (const K &k)
 
constexpr bool contains (const K &k) const
 
template<typename F>
requires requires(F f, const K &k, T &v) { f(k, v); }
constexpr void for_each (F f)
 
constexpr void clear ()
 

Member Function Documentation

◆ operator[]()

template<typename K, typename T, typename Hash = internal::hashing::HashObject<K>, bool KEEP_HISTORY = false, int LG = 20>
T & maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG >::operator[] ( const K & k)
inlineconstexpr

◆ erase()

template<typename K, typename T, typename Hash = internal::hashing::HashObject<K>, bool KEEP_HISTORY = false, int LG = 20>
bool maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG >::erase ( const K & k)
inlineconstexpr

◆ contains()

template<typename K, typename T, typename Hash = internal::hashing::HashObject<K>, bool KEEP_HISTORY = false, int LG = 20>
bool maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG >::contains ( const K & k) const
inlineconstexpr

◆ for_each()

template<typename K, typename T, typename Hash = internal::hashing::HashObject<K>, bool KEEP_HISTORY = false, int LG = 20>
template<typename F>
requires requires(F f, const K &k, T &v) { f(k, v); }
void maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG >::for_each ( F f)
inlineconstexpr

◆ clear()

template<typename K, typename T, typename Hash = internal::hashing::HashObject<K>, bool KEEP_HISTORY = false, int LG = 20>
void maomao90::HashMap< K, T, Hash, KEEP_HISTORY, LG >::clear ( )
inlineconstexpr

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