FastLED 3.9.3
Loading...
Searching...
No Matches
FixedMap< Key, Value, N > Class Template Reference

Detailed Description

template<typename Key, typename Value, size_t N>
class FixedMap< Key, Value, N >

Definition at line 17 of file fixed_map.h.

Classes

struct  Pair
 

Public Types

typedef FixedVector< Pair, N > VectorType
 
typedef VectorType::iterator iterator
 
typedef VectorType::const_iterator const_iterator
 

Public Member Functions

iterator begin ()
 
iterator end ()
 
const_iterator begin () const
 
const_iterator end () const
 
iterator find (const Key &key)
 
const_iterator find (const Key &key) const
 
bool get (const Key &key, Value *value) const
 
Value get (const Key &key, bool *has=nullptr) const
 
bool insert (const Key &key, const Value &value)
 
bool update (const Key &key, const Value &value, bool insert_if_missing=true)
 
Value & operator[] (const Key &key)
 
const Value & operator[] (const Key &key) const
 
bool next (const Key &key, Key *next_key, bool allow_rollover=false) const
 
bool prev (const Key &key, Key *prev_key, bool allow_rollover=false) const
 
constexpr size_t size () const
 
constexpr bool empty () const
 
constexpr size_t capacity () const
 
void clear ()
 
bool has (const Key &it) const
 

Member Typedef Documentation

◆ const_iterator

template<typename Key , typename Value , size_t N>
typedef VectorType::const_iterator FixedMap< Key, Value, N >::const_iterator

Definition at line 27 of file fixed_map.h.

◆ iterator

template<typename Key , typename Value , size_t N>
typedef VectorType::iterator FixedMap< Key, Value, N >::iterator

Definition at line 26 of file fixed_map.h.

◆ VectorType

template<typename Key , typename Value , size_t N>
typedef FixedVector<Pair, N> FixedMap< Key, Value, N >::VectorType

Definition at line 25 of file fixed_map.h.

Member Function Documentation

◆ begin() [1/2]

template<typename Key , typename Value , size_t N>
iterator FixedMap< Key, Value, N >::begin ( )
inline

Definition at line 33 of file fixed_map.h.

◆ begin() [2/2]

template<typename Key , typename Value , size_t N>
const_iterator FixedMap< Key, Value, N >::begin ( ) const
inline

Definition at line 39 of file fixed_map.h.

◆ capacity()

template<typename Key , typename Value , size_t N>
size_t FixedMap< Key, Value, N >::capacity ( ) const
inlineconstexpr

Definition at line 170 of file fixed_map.h.

◆ clear()

template<typename Key , typename Value , size_t N>
void FixedMap< Key, Value, N >::clear ( )
inline

Definition at line 175 of file fixed_map.h.

◆ empty()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::empty ( ) const
inlineconstexpr

Definition at line 165 of file fixed_map.h.

◆ end() [1/2]

template<typename Key , typename Value , size_t N>
iterator FixedMap< Key, Value, N >::end ( )
inline

Definition at line 36 of file fixed_map.h.

◆ end() [2/2]

template<typename Key , typename Value , size_t N>
const_iterator FixedMap< Key, Value, N >::end ( ) const
inline

Definition at line 42 of file fixed_map.h.

◆ find() [1/2]

template<typename Key , typename Value , size_t N>
iterator FixedMap< Key, Value, N >::find ( const Key & key)
inline

Definition at line 46 of file fixed_map.h.

◆ find() [2/2]

template<typename Key , typename Value , size_t N>
const_iterator FixedMap< Key, Value, N >::find ( const Key & key) const
inline

Definition at line 55 of file fixed_map.h.

◆ get() [1/2]

template<typename Key , typename Value , size_t N>
Value FixedMap< Key, Value, N >::get ( const Key & key,
bool * has = nullptr ) const
inline

Definition at line 75 of file fixed_map.h.

◆ get() [2/2]

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::get ( const Key & key,
Value * value ) const
inline

Definition at line 66 of file fixed_map.h.

◆ has()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::has ( const Key & it) const
inline

Definition at line 179 of file fixed_map.h.

◆ insert()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::insert ( const Key & key,
const Value & value )
inline

Definition at line 89 of file fixed_map.h.

◆ next()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::next ( const Key & key,
Key * next_key,
bool allow_rollover = false ) const
inline

Definition at line 129 of file fixed_map.h.

◆ operator[]() [1/2]

template<typename Key , typename Value , size_t N>
Value & FixedMap< Key, Value, N >::operator[] ( const Key & key)
inline

Definition at line 111 of file fixed_map.h.

◆ operator[]() [2/2]

template<typename Key , typename Value , size_t N>
const Value & FixedMap< Key, Value, N >::operator[] ( const Key & key) const
inline

Definition at line 120 of file fixed_map.h.

◆ prev()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::prev ( const Key & key,
Key * prev_key,
bool allow_rollover = false ) const
inline

Definition at line 144 of file fixed_map.h.

◆ size()

template<typename Key , typename Value , size_t N>
size_t FixedMap< Key, Value, N >::size ( ) const
inlineconstexpr

Definition at line 161 of file fixed_map.h.

◆ update()

template<typename Key , typename Value , size_t N>
bool FixedMap< Key, Value, N >::update ( const Key & key,
const Value & value,
bool insert_if_missing = true )
inline

Definition at line 100 of file fixed_map.h.


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