Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
ireference_flat_set< T, TKeyCompare > Class Template Reference
The base class for specifically sized reference_flat_sets. More...
#include <reference_flat_set.h>
Inherited by iflat_set< T, TKeyCompare > [private]
.
Public Member Functions | |
iterator | begin () |
Returns an iterator to the beginning of the reference_flat_set. | |
const_iterator | begin () const |
Returns a const_iterator to the beginning of the reference_flat_set. | |
iterator | end () |
Returns an iterator to the end of the reference_flat_set. | |
const_iterator | end () const |
Returns a const_iterator to the end of the reference_flat_set. | |
const_iterator | cbegin () const |
Returns a const_iterator to the beginning of the reference_flat_set. | |
const_iterator | cend () const |
Returns a const_iterator to the end of the reference_flat_set. | |
reverse_iterator | rbegin () |
Returns an reverse iterator to the reverse beginning of the reference_flat_set. | |
const_reverse_iterator | rbegin () const |
Returns a const reverse iterator to the reverse beginning of the reference_flat_set. | |
reverse_iterator | rend () |
Returns a reverse iterator to the end + 1 of the reference_flat_set. | |
const_reverse_iterator | rend () const |
Returns a const reverse iterator to the end + 1 of the reference_flat_set. | |
const_reverse_iterator | crbegin () const |
Returns a const reverse iterator to the reverse beginning of the reference_flat_set. | |
const_reverse_iterator | crend () const |
Returns a const reverse iterator to the end + 1 of the reference_flat_set. | |
template<typename TIterator > | |
void | assign (TIterator first, TIterator last) |
Assigns values to the reference_flat_set. | |
std::pair< iterator, bool > | insert (reference value) |
Inserts a value to the reference_flat_set. | |
iterator | insert (iterator position, reference value) |
Inserts a value to the reference_flat_set. | |
template<class TIterator > | |
void | insert (TIterator first, TIterator last) |
Inserts a range of values to the reference_flat_set. | |
size_t | erase (parameter_t key) |
Erases an element. | |
void | erase (iterator i_element) |
Erases an element. | |
void | erase (iterator first, iterator last) |
Erases a range of elements. | |
void | clear () |
Clears the reference_flat_set. | |
iterator | find (parameter_t key) |
Finds an element. | |
const_iterator | find (parameter_t key) const |
Finds an element. | |
size_t | count (parameter_t key) const |
Counts an element. | |
iterator | lower_bound (parameter_t key) |
Finds the lower bound of a key. | |
const_iterator | lower_bound (parameter_t key) const |
Finds the lower bound of a key. | |
iterator | upper_bound (parameter_t key) |
Finds the upper bound of a key. | |
const_iterator | upper_bound (parameter_t key) const |
Finds the upper bound of a key. | |
std::pair< iterator, iterator > | equal_range (parameter_t key) |
Finds the range of equal elements of a key. | |
std::pair< const_iterator, const_iterator > | equal_range (parameter_t key) const |
Finds the range of equal elements of a key. | |
size_type | size () const |
Gets the current size of the reference_flat_set. | |
bool | empty () const |
Checks the 'empty' state of the reference_flat_set. | |
bool | full () const |
Checks the 'full' state of the reference_flat_set. | |
size_type | capacity () const |
Returns the capacity of the reference_flat_set. | |
size_type | max_size () const |
Returns the maximum possible size of the reference_flat_set. | |
size_t | available () const |
Returns the remaining capacity. | |
Protected Member Functions | |
ireference_flat_set (lookup_t &lookup_) | |
Constructor. | |
std::pair< iterator, bool > | insert_at (iterator i_element, reference value) |
Inserts a value to the reference_flat_set. |
Detailed Description
template<typename T, typename TKeyCompare = std::less<T>>
class etl::ireference_flat_set< T, TKeyCompare >
The base class for specifically sized reference_flat_sets.
Can be used as a reference type for all reference_flat_sets containing a specific type.
Definition at line 100 of file reference_flat_set.h.
Constructor & Destructor Documentation
ireference_flat_set | ( | lookup_t & | lookup_ ) | [protected] |
Constructor.
Definition at line 717 of file reference_flat_set.h.
Member Function Documentation
void assign | ( | TIterator | first, |
TIterator | last | ||
) |
Assigns values to the reference_flat_set.
If asserts or exceptions are enabled, emits reference_flat_set_full if the reference_flat_set does not have enough free space. If asserts or exceptions are enabled, emits reference_flat_set_iterator if the iterators are reversed.
- Parameters:
-
first The iterator to the first element. last The iterator to the last element + 1.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 437 of file reference_flat_set.h.
size_t available | ( | ) | const |
Returns the remaining capacity.
- Returns:
- The remaining capacity.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 707 of file reference_flat_set.h.
const_iterator begin | ( | ) | const |
Returns a const_iterator to the beginning of the reference_flat_set.
- Returns:
- A const iterator to the beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 334 of file reference_flat_set.h.
iterator begin | ( | ) |
Returns an iterator to the beginning of the reference_flat_set.
- Returns:
- An iterator to the beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 325 of file reference_flat_set.h.
size_type capacity | ( | ) | const |
Returns the capacity of the reference_flat_set.
- Returns:
- The capacity of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 689 of file reference_flat_set.h.
const_iterator cbegin | ( | ) | const |
Returns a const_iterator to the beginning of the reference_flat_set.
- Returns:
- A const iterator to the beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 361 of file reference_flat_set.h.
const_iterator cend | ( | ) | const |
Returns a const_iterator to the end of the reference_flat_set.
- Returns:
- A const iterator to the end of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 370 of file reference_flat_set.h.
void clear | ( | ) |
Clears the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 535 of file reference_flat_set.h.
size_t count | ( | parameter_t | key ) | const |
Counts an element.
- Parameters:
-
key The key to search for.
- Returns:
- 1 if the key exists, otherwise 0.
Definition at line 593 of file reference_flat_set.h.
const_reverse_iterator crbegin | ( | ) | const |
Returns a const reverse iterator to the reverse beginning of the reference_flat_set.
- Returns:
- Const reverse iterator to the reverse beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 415 of file reference_flat_set.h.
const_reverse_iterator crend | ( | ) | const |
Returns a const reverse iterator to the end + 1 of the reference_flat_set.
- Returns:
- Const reverse iterator to the end + 1 of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 424 of file reference_flat_set.h.
bool empty | ( | ) | const |
Checks the 'empty' state of the reference_flat_set.
- Returns:
- true if empty.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 671 of file reference_flat_set.h.
const_iterator end | ( | ) | const |
Returns a const_iterator to the end of the reference_flat_set.
- Returns:
- A const iterator to the end of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 352 of file reference_flat_set.h.
iterator end | ( | ) |
Returns an iterator to the end of the reference_flat_set.
- Returns:
- An iterator to the end of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 343 of file reference_flat_set.h.
std::pair<const_iterator, const_iterator> equal_range | ( | parameter_t | key ) | const |
Finds the range of equal elements of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator pair.
Definition at line 653 of file reference_flat_set.h.
std::pair<iterator, iterator> equal_range | ( | parameter_t | key ) |
Finds the range of equal elements of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator pair.
Definition at line 643 of file reference_flat_set.h.
size_t erase | ( | parameter_t | key ) |
Erases an element.
- Parameters:
-
key The key to erase.
- Returns:
- The number of elements erased. 0 or 1.
Definition at line 496 of file reference_flat_set.h.
void erase | ( | iterator | i_element ) |
Erases an element.
- Parameters:
-
i_element Iterator to the element.
Reimplemented in iflat_set< T, TKeyCompare >.
Definition at line 515 of file reference_flat_set.h.
void erase | ( | iterator | first, |
iterator | last | ||
) |
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.
Reimplemented in iflat_set< T, TKeyCompare >.
Definition at line 527 of file reference_flat_set.h.
iterator find | ( | parameter_t | key ) |
Finds an element.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator pointing to the element or end() if not found.
Definition at line 545 of file reference_flat_set.h.
const_iterator find | ( | parameter_t | key ) | const |
Finds an element.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator pointing to the element or end() if not found.
Definition at line 569 of file reference_flat_set.h.
bool full | ( | ) | const |
Checks the 'full' state of the reference_flat_set.
- Returns:
- true if full.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 680 of file reference_flat_set.h.
void insert | ( | TIterator | first, |
TIterator | last | ||
) |
Inserts a range of values to the reference_flat_set.
If asserts or exceptions are enabled, emits reference_flat_set_full if the reference_flat_set 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.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 483 of file reference_flat_set.h.
std::pair<iterator, bool> insert | ( | reference | value ) |
Inserts a value to the reference_flat_set.
If asserts or exceptions are enabled, emits reference_flat_set_full if the reference_flat_set is already full.
- Parameters:
-
value The value to insert.
Definition at line 457 of file reference_flat_set.h.
iterator insert | ( | iterator | position, |
reference | value | ||
) |
Inserts a value to the reference_flat_set.
If asserts or exceptions are enabled, emits reference_flat_set_full if the reference_flat_set is already full.
- Parameters:
-
position The position to insert at. value The value to insert.
Definition at line 470 of file reference_flat_set.h.
std::pair<iterator, bool> insert_at | ( | iterator | i_element, |
reference | value | ||
) | [protected] |
Inserts a value to the reference_flat_set.
- Parameters:
-
i_element The place to insert. value The value to insert.
Definition at line 727 of file reference_flat_set.h.
const_iterator lower_bound | ( | parameter_t | key ) | const |
Finds the lower bound of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator.
Definition at line 613 of file reference_flat_set.h.
iterator lower_bound | ( | parameter_t | key ) |
Finds the lower bound of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator.
Definition at line 603 of file reference_flat_set.h.
size_type max_size | ( | ) | const |
Returns the maximum possible size of the reference_flat_set.
- Returns:
- The maximum size of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 698 of file reference_flat_set.h.
reverse_iterator rbegin | ( | ) |
Returns an reverse iterator to the reverse beginning of the reference_flat_set.
- Returns:
- Iterator to the reverse beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 379 of file reference_flat_set.h.
const_reverse_iterator rbegin | ( | ) | const |
Returns a const reverse iterator to the reverse beginning of the reference_flat_set.
- Returns:
- Const iterator to the reverse beginning of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 388 of file reference_flat_set.h.
const_reverse_iterator rend | ( | ) | const |
Returns a const reverse iterator to the end + 1 of the reference_flat_set.
- Returns:
- Const reverse iterator to the end + 1 of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 406 of file reference_flat_set.h.
reverse_iterator rend | ( | ) |
Returns a reverse iterator to the end + 1 of the reference_flat_set.
- Returns:
- Reverse iterator to the end + 1 of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 397 of file reference_flat_set.h.
size_type size | ( | ) | const |
Gets the current size of the reference_flat_set.
- Returns:
- The current size of the reference_flat_set.
Reimplemented in iflat_set< T, TKeyCompare >, and iflat_set< T, TCompare >.
Definition at line 662 of file reference_flat_set.h.
const_iterator upper_bound | ( | parameter_t | key ) | const |
Finds the upper bound of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator.
Definition at line 633 of file reference_flat_set.h.
iterator upper_bound | ( | parameter_t | key ) |
Finds the upper bound of a key.
- Parameters:
-
key The key to search for.
- Returns:
- An iterator.
Definition at line 623 of file reference_flat_set.h.
Generated on Tue Jul 12 2022 14:05:53 by
