ADS
Algorithms and Data Structures
Loading...
Searching...
No Matches
ADS::BPlusTree< K, V >::const_iterator Class Reference

the iterator on the pairs by increasing keys, a leaf and a place in it More...

#include <ADS/tree/BPlusTree.h>

Public types

using reference
 a pair of constant references, the key and its value (that of the vector of the values, a proxy if V is bool), whose value is ( K , V )
using value_type = std::pair< K , V >
 the pairs, by value
using difference_type = std::ptrdiff_t
 the type of the distances
using iterator_concept = std::bidirectional_iterator_tag
 the category of the iterator for the concepts of C++20, bidirectional
using iterator_category = std::input_iterator_tag
 input for the older algorithms, since *it is a value

Public member functions

 const_iterator (void)=default
 an iterator on no tree
 const_iterator (const BPlusTree *t, const Node *f, std::size_t i)
 on the place \( i \) of the leaf \( f \) of the tree \( t \), the end if \( f \) is nil
reference operator* (void) const
 the pair of the place
const_iterator & operator++ (void)
 to the next pair, along the list of the leaves
const_iterator & operator-- (void)
 to the previous pair, from the end to the last pair
const_iterator operator++ (int)
 to the next pair, returning the iterator before the step
const_iterator operator-- (int)
 to the previous pair, returning the iterator before the step
bool operator== (const const_iterator &o) const
 equal on the same place of the same leaf

Detailed description

template<std::totally_ordered K, class V>
class ADS::BPlusTree< K, V >::const_iterator

the iterator on the pairs by increasing keys, a leaf and a place in it

Member typedef documentation

◆ difference_type

template<std::totally_ordered K, class V>
using ADS::BPlusTree< K, V >::const_iterator::difference_type = std::ptrdiff_t

the type of the distances

◆ iterator_category

template<std::totally_ordered K, class V>
using ADS::BPlusTree< K, V >::const_iterator::iterator_category = std::input_iterator_tag

input for the older algorithms, since *it is a value

◆ iterator_concept

template<std::totally_ordered K, class V>
using ADS::BPlusTree< K, V >::const_iterator::iterator_concept = std::bidirectional_iterator_tag

the category of the iterator for the concepts of C++20, bidirectional

◆ reference

template<std::totally_ordered K, class V>
using ADS::BPlusTree< K, V >::const_iterator::reference
Initial value:
std::conditional_t< detail::plainPair< A, B, VA, VB >, std::pair< A, B >, detail::PairProxy< A, B, VA, VB > > PairRef
the pair that an iterator reads by value, in general two references into the container,...
Definition Iterators.h:648

a pair of constant references, the key and its value (that of the vector of the values, a proxy if V is bool), whose value is ( K , V )

◆ value_type

template<std::totally_ordered K, class V>
using ADS::BPlusTree< K, V >::const_iterator::value_type = std::pair< K , V >

the pairs, by value

Constructor and destructor documentation

◆ const_iterator() [1/2]

template<std::totally_ordered K, class V>
ADS::BPlusTree< K, V >::const_iterator::const_iterator ( void )
default

an iterator on no tree

◆ const_iterator() [2/2]

template<std::totally_ordered K, class V>
ADS::BPlusTree< K, V >::const_iterator::const_iterator ( const BPlusTree * t,
const Node * f,
std::size_t i )
inline

on the place \( i \) of the leaf \( f \) of the tree \( t \), the end if \( f \) is nil

Member function documentation

◆ operator*()

template<std::totally_ordered K, class V>
reference ADS::BPlusTree< K, V >::const_iterator::operator* ( void ) const
inline

the pair of the place

◆ operator++() [1/2]

template<std::totally_ordered K, class V>
const_iterator ADS::BPlusTree< K, V >::const_iterator::operator++ ( int )
inline

to the next pair, returning the iterator before the step

◆ operator++() [2/2]

template<std::totally_ordered K, class V>
const_iterator & ADS::BPlusTree< K, V >::const_iterator::operator++ ( void )
inline

to the next pair, along the list of the leaves

◆ operator--() [1/2]

template<std::totally_ordered K, class V>
const_iterator ADS::BPlusTree< K, V >::const_iterator::operator-- ( int )
inline

to the previous pair, returning the iterator before the step

◆ operator--() [2/2]

template<std::totally_ordered K, class V>
const_iterator & ADS::BPlusTree< K, V >::const_iterator::operator-- ( void )
inline

to the previous pair, from the end to the last pair

◆ operator==()

template<std::totally_ordered K, class V>
bool ADS::BPlusTree< K, V >::const_iterator::operator== ( const const_iterator & o) const
inline

equal on the same place of the same leaf


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