Iterator adaptor that recursively flattens the sequence of a given iterator over a nested sequence.
More...
|
| | Flat_iterator ()=default |
| |
| | Flat_iterator (const Outer_range_t &outer_range, const Outer_iterator_t &outer_iterator) |
| |
| | Flat_iterator (const Outer_range_t &outer_range) |
| |
| decltype(auto) | get () const |
| |
| void | next () |
| |
| bool | is_equal (const Flat_iterator &other) const |
| |
| decltype(auto) | operator* () const |
| | Dereference operator, which returns the current value. More...
|
| |
| auto | operator-> () const |
| | Arrow operator, return a pointer (possibly a fancy pointer) to the current element. More...
|
| |
| Self_t & | operator++ () |
| | Pre-increment operator, which advances the position one step and returns a reference to the iterator itself. More...
|
| |
| auto | operator++ (int) |
| | Post-increment operator, which advances the position one step. More...
|
| |
| Self_t & | operator-- () |
| | Pre-decrement iterator, which moves one step back and returns a reference to the iterator itself. More...
|
| |
| auto | operator-- (int) |
| | Post-decrement operator, which moves one step back and returns a copy of the iterator before the decrement. More...
|
| |
| Self_t & | operator+= (std::ptrdiff_t delta) |
| | Addition assignment operator, which moves the iterator forward by the given number of steps, and returns a reference to the iterator itself. More...
|
| |
| Self_t & | operator-= (std::ptrdiff_t delta) |
| | Subtraction assignment operator, which moves the iterator backward by the given number of steps, and returns a reference to the iterator itself. More...
|
| |
| Self_t | operator+ (std::ptrdiff_t delta) const |
| | Addition operator, which returns a new iterator that is the given number of steps ahead of the current iterator. More...
|
| |
| Self_t | operator- (std::ptrdiff_t delta) const |
| | Subtraction-of-integer operator, which returns a new iterator that is the given number of steps behind of the current iterator. More...
|
| |
| std::ptrdiff_t | operator- (const Self_t &other) const |
| | Subtraction-of-iterator operator, which returns the number of steps from other this. More...
|
| |
| decltype(auto) | operator[] (std::ptrdiff_t delta) const |
| | Subscript operator, which returns a new iterator that is the given number of steps ahead of the current iterator. More...
|
| |
template<class Outer_range_tp, class Unfold_tp>
class mysql::ranges::Flat_iterator< Outer_range_tp, Unfold_tp >
Iterator adaptor that recursively flattens the sequence of a given iterator over a nested sequence.
For each value v yielded by iterators of the range unfolded from the given source, this iterator recursively flattens the range given by Unfold_t::unfold(v), and yields all elements in that flattened sequence.
This iterator implements the recursive step of procedure to flatten a range. The base case occurs when Unfold::unfold(v) is not defined, in which case make_flat_view provides the range unfolded from the source without using this class to attempt to flatten it.
- Template Parameters
-
| Outer_range_tp | Type of the outermost range. It is required that Unfold_tp::unfold(v) is defined, where v is an object of the range's value type. |
| Unfold_tp | Class to obtain range views from the range's values; from the values of those range views, and so on, recursively. |