Loading...
Searching...
No Matches
etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare > Class Template Reference

`#include <reference_flat_multimap.h>`

## Classes

class | iterator
class | const_iterator

## Public Types

typedef ETL_OR_STD::pair< const TKey, TMapped > | value_type
typedef TKey | key_type
typedef TMapped | mapped_type
typedef TKeyCompare | key_compare
typedef value_type & | reference
typedef const value_type & | const_reference
typedef value_type * | pointer
typedef const value_type * | const_pointer
typedef size_t | size_type
typedef ETL_OR_STD::reverse_iterator< iterator > | reverse_iterator
typedef ETL_OR_STD::reverse_iterator< const_iterator > | const_reverse_iterator
typedef etl::iterator_traits< iterator >::difference_type | difference_type

## Public Member Functions

iterator | begin ()
const_iterator | begin () const
iterator | end ()
const_iterator | end () const
const_iterator | cbegin () const
const_iterator | cend () const
reverse_iterator | rbegin ()
const_reverse_iterator | rbegin () const
reverse_iterator | rend ()
const_reverse_iterator | rend () const
const_reverse_iterator | crbegin () const
const_reverse_iterator | crend () const
template<typename TIterator>
void | assign (TIterator first, TIterator last)
ETL_OR_STD::pair< iterator, bool > | insert (value_type &value)
ETL_OR_STD::pair< iterator, bool > | emplace (value_type &value)
iterator | insert (const_iterator, const value_type &value)
template<class TIterator>
void | insert (TIterator first, TIterator last)
size_t | erase (key_parameter_t key)
iterator | erase (iterator i_element)
iterator | erase (const_iterator i_element)
iterator | erase (const_iterator first, const_iterator last)
void | clear ()
| Clears the reference_flat_multimap.
iterator | find (key_parameter_t key)
const_iterator | find (key_parameter_t key) const
size_t | count (key_parameter_t key) const
iterator | lower_bound (key_parameter_t key)
const_iterator | lower_bound (key_parameter_t key) const
iterator | upper_bound (key_parameter_t key)
const_iterator | upper_bound (key_parameter_t key) const
ETL_OR_STD::pair< iterator, iterator > | equal_range (key_parameter_t key)
ETL_OR_STD::pair< const_iterator, const_iterator > | equal_range (key_parameter_t key) const
bool | contains (const TKey &key) const
| Check if the map contains the key.
size_type | size () const
bool | empty () const
bool | full () const
size_type | capacity () const
size_type | max_size () const
size_t | available () const

## Protected Types

typedef etl::ivector< value_type * > | lookup_t
typedef const TKey & | key_parameter_t

## Protected Member Functions

| ireference_flat_multimap (lookup_t &lookup_)
| Constructor.
ETL_OR_STD::pair< iterator, bool > | insert_at (iterator i_element, value_type &value)
| ~ireference_flat_multimap ()
| Destructor.

## Detailed Description

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>
class etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >

The base class for specifically sized reference_flat_multimaps. Can be used as a reference type for all reference_flat_multimaps containing a specific type.

## Member Function Documentation

## assign()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>
template<typename TIterator>

void etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::assign | ( | TIterator | first,
|  | TIterator | last )

inline

Assigns values to the reference_flat_multimap. If asserts or exceptions are enabled, emits reference_flat_multimap_full if the reference_flat_multimap does not have enough free space. If asserts or exceptions are enabled, emits reference_flat_multimap_iterator if the iterators are reversed.

Parameters

  first | The iterator to the first element.
  last | The iterator to the last element + 1.

## available()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_t etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::available | ( |  | ) | const

inline

Returns the remaining capacity.

Returns
  The remaining capacity.

## begin() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::begin | ( |  | ) |

inline

Returns an iterator to the beginning of the reference_flat_multimap.

Returns
  An iterator to the beginning of the reference_flat_multimap.

## begin() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::begin | ( |  | ) | const

inline

Returns a const_iterator to the beginning of the reference_flat_multimap.

Returns
  A const iterator to the beginning of the reference_flat_multimap.

## capacity()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_type etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::capacity | ( |  | ) | const

inline

Returns the capacity of the flat_multiset.

Returns
  The capacity of the flat_multiset.

## cbegin()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::cbegin | ( |  | ) | const

inline

Returns a const_iterator to the beginning of the reference_flat_multimap.

Returns
  A const iterator to the beginning of the reference_flat_multimap.

## cend()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::cend | ( |  | ) | const

inline

Returns a const_iterator to the end of the reference_flat_multimap.

Returns
  A const iterator to the end of the reference_flat_multimap.

## count()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_t etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::count | ( | key_parameter_t | key | ) | const

inline

Counts an element.

Parameters

  key | The key to search for.

Returns
  1 if the key exists, otherwise 0.

## crbegin()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::crbegin | ( |  | ) | const

inline

Returns a const reverse iterator to the reverse beginning of the reference_flat_multimap.

Returns
  Const reverse iterator to the reverse beginning of the reference_flat_multimap.

## crend()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::crend | ( |  | ) | const

inline

Returns a const reverse iterator to the end + 1 of the reference_flat_multimap.

Returns
  Const reverse iterator to the end + 1 of the reference_flat_multimap.

## emplace()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

ETL_OR_STD::pair< iterator, bool > etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::emplace | ( | value_type & | value | ) |

inline

Emplaces a value to the reference_flat_multimap. As the reference_flat_multimap stores references to externally owned objects, the value is not constructed in place but inserted by reference.

Parameters

  value | The value to emplace.

## empty()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

bool etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::empty | ( |  | ) | const

inline

Checks the 'empty' state of the flat_multiset.

Returns
  true if empty.

## end() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::end | ( |  | ) |

inline

Returns an iterator to the end of the reference_flat_multimap.

Returns
  An iterator to the end of the reference_flat_multimap.

## end() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::end | ( |  | ) | const

inline

Returns a const_iterator to the end of the reference_flat_multimap.

Returns
  A const iterator to the end of the reference_flat_multimap.

## equal_range() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

ETL_OR_STD::pair< iterator, iterator > etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::equal_range | ( | key_parameter_t | key | ) |

inline

Finds the range of equal elements of a key

Parameters

  key | The key to search for.

Returns
  An iterator pair.

## equal_range() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

ETL_OR_STD::pair< const_iterator, const_iterator > etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::equal_range | ( | key_parameter_t | key | ) | const

inline

Finds the range of equal elements of a key

Parameters

  key | The key to search for.

Returns
  An iterator pair.

## erase() [1/4]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::erase | ( | const_iterator | first,
|  | const_iterator | last )

inline

Erases a range of elements. The range includes all the elements between first and last, including the element pointed by first, but not the one pointed by last.

Parameters

  first | Iterator to the first element.
  last | Iterator to the last element.

## erase() [2/4]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::erase | ( | const_iterator | i_element | ) |

inline

Erases an element.

Parameters

  i_element | Iterator to the element.

## erase() [3/4]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::erase | ( | iterator | i_element | ) |

inline

Erases an element.

Parameters

  i_element | Iterator to the element.

## erase() [4/4]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_t etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::erase | ( | key_parameter_t | key | ) |

inline

Erases an element.

Parameters

  key | The key to erase.

Returns
  The number of elements erased. 0 or 1.

## find() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::find | ( | key_parameter_t | key | ) |

inline

Finds an element.

Parameters

  key | The key to search for.

Returns
  An iterator pointing to the element or end() if not found.

## find() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::find | ( | key_parameter_t | key | ) | const

inline

Finds an element.

Parameters

  key | The key to search for.

Returns
  An iterator pointing to the element or end() if not found.

## full()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

bool etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::full | ( |  | ) | const

inline

Checks the 'full' state of the flat_multiset.

Returns
  true if full.

## insert() [1/3]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::insert | ( | const_iterator | ,
|  | const value_type & | value )

inline

Inserts a value to the flat_multi. If asserts or exceptions are enabled, emits flat_map_full if the flat_map is already full.

Parameters

  position | The position to insert at.
  value | The value to insert.

## insert() [2/3]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>
template<class TIterator>

void etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::insert | ( | TIterator | first,
|  | TIterator | last )

inline

Inserts a range of values to the reference_flat_multimap. If asserts or exceptions are enabled, emits reference_flat_multimap_full if the reference_flat_multimap does not have enough free space.

Parameters

  position | The position to insert at.
  first | The first element to add.
  last | The last + 1 element to add.

## insert() [3/3]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

ETL_OR_STD::pair< iterator, bool > etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::insert | ( | value_type & | value | ) |

inline

Inserts a value to the reference_flat_multimap. If asserts or exceptions are enabled, emits reference_flat_multimap_full if the reference_flat_multimap is already full.

Parameters

  value | The value to insert.

## insert_at()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

ETL_OR_STD::pair< iterator, bool > etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::insert_at | ( | iterator | i_element,
|  | value_type & | value )

inline protected

Inserts a value to the reference_flat_multimap.

Parameters

  i_element | The place to insert.
  value | The value to insert.

## lower_bound() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::lower_bound | ( | key_parameter_t | key | ) |

inline

Finds the lower bound of a key

Parameters

  key | The key to search for.

Returns
  An iterator.

## lower_bound() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::lower_bound | ( | key_parameter_t | key | ) | const

inline

Finds the lower bound of a key

Parameters

  key | The key to search for.

Returns
  An iterator.

## max_size()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_type etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::max_size | ( |  | ) | const

inline

Returns the maximum possible size of the flat_multiset.

Returns
  The maximum size of the flat_multiset.

## rbegin() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::rbegin | ( |  | ) |

inline

Returns an reverse iterator to the reverse beginning of the reference_flat_multimap.

Returns
  Iterator to the reverse beginning of the reference_flat_multimap.

## rbegin() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::rbegin | ( |  | ) | const

inline

Returns a const reverse iterator to the reverse beginning of the reference_flat_multimap.

Returns
  Const iterator to the reverse beginning of the reference_flat_multimap.

## rend() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::rend | ( |  | ) |

inline

Returns a reverse iterator to the end + 1 of the reference_flat_multimap.

Returns
  Reverse iterator to the end + 1 of the reference_flat_multimap.

## rend() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_reverse_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::rend | ( |  | ) | const

inline

Returns a const reverse iterator to the end + 1 of the reference_flat_multimap.

Returns
  Const reverse iterator to the end + 1 of the reference_flat_multimap.

## size()

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

size_type etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::size | ( |  | ) | const

inline

Gets the current size of the flat_multiset.

Returns
  The current size of the flat_multiset.

## upper_bound() [1/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::upper_bound | ( | key_parameter_t | key | ) |

inline

Finds the upper bound of a key

Parameters

  key | The key to search for.

Returns
  An iterator.

## upper_bound() [2/2]

template<typename TKey, typename TMapped, typename TKeyCompare = etl::less<TKey>>

const_iterator etl::ireference_flat_multimap< TKey, TMapped, TKeyCompare >::upper_bound | ( | key_parameter_t | key | ) | const

inline

Finds the upper bound of a key

Parameters

  key | The key to search for.

Returns
  An iterator.

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

- include/etl/reference_flat_multimap.h