C++ Library Extensions 2022.12.09
To help learn modern C++ programming
tbb::counting_iterator< IntType > Class Template Reference

#include <cpg_iterator.hpp>

Public Types

typedef std::make_signed< IntType >::type difference_type
 
typedef IntType value_type
 
typedef const IntType * pointer
 
typedef const IntType & reference
 
typedef std::random_access_iterator_tag iterator_category
 

Public Member Functions

 counting_iterator ()
 
 counting_iterator (IntType init)
 
reference operator* () const
 
value_type operator[] (difference_type i) const
 
difference_type operator- (const counting_iterator &it) const
 
counting_iteratoroperator+= (difference_type forward)
 
counting_iteratoroperator-= (difference_type backward)
 
counting_iteratoroperator++ ()
 
counting_iteratoroperator-- ()
 
counting_iterator operator++ (int)
 
counting_iterator operator-- (int)
 
counting_iterator operator- (difference_type backward) const
 
counting_iterator operator+ (difference_type forward) const
 
bool operator== (const counting_iterator &it) const
 
bool operator!= (const counting_iterator &it) const
 
bool operator< (const counting_iterator &it) const
 
bool operator> (const counting_iterator &it) const
 
bool operator<= (const counting_iterator &it) const
 
bool operator>= (const counting_iterator &it) const
 

Friends

counting_iterator operator+ (difference_type forward, const counting_iterator it)
 

Detailed Description

template<typename IntType>
class tbb::counting_iterator< IntType >

Definition at line 23 of file cpg_iterator.hpp.

Member Typedef Documentation

◆ difference_type

template<typename IntType >
typedef std::make_signed<IntType>::type tbb::counting_iterator< IntType >::difference_type

Definition at line 27 of file cpg_iterator.hpp.

◆ iterator_category

template<typename IntType >
typedef std::random_access_iterator_tag tbb::counting_iterator< IntType >::iterator_category

Definition at line 31 of file cpg_iterator.hpp.

◆ pointer

template<typename IntType >
typedef const IntType* tbb::counting_iterator< IntType >::pointer

Definition at line 29 of file cpg_iterator.hpp.

◆ reference

template<typename IntType >
typedef const IntType& tbb::counting_iterator< IntType >::reference

Definition at line 30 of file cpg_iterator.hpp.

◆ value_type

template<typename IntType >
typedef IntType tbb::counting_iterator< IntType >::value_type

Definition at line 28 of file cpg_iterator.hpp.

Constructor & Destructor Documentation

◆ counting_iterator() [1/2]

template<typename IntType >
tbb::counting_iterator< IntType >::counting_iterator ( )
inline

Definition at line 33 of file cpg_iterator.hpp.

Here is the caller graph for this function:

◆ counting_iterator() [2/2]

template<typename IntType >
tbb::counting_iterator< IntType >::counting_iterator ( IntType  init)
inlineexplicit

Definition at line 34 of file cpg_iterator.hpp.

Member Function Documentation

◆ operator!=()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator!= ( const counting_iterator< IntType > &  it) const
inline

Definition at line 62 of file cpg_iterator.hpp.

◆ operator*()

template<typename IntType >
reference tbb::counting_iterator< IntType >::operator* ( ) const
inline

Definition at line 36 of file cpg_iterator.hpp.

◆ operator+()

template<typename IntType >
counting_iterator tbb::counting_iterator< IntType >::operator+ ( difference_type  forward) const
inline

Definition at line 58 of file cpg_iterator.hpp.

Here is the call graph for this function:

◆ operator++() [1/2]

template<typename IntType >
counting_iterator & tbb::counting_iterator< IntType >::operator++ ( )
inline

Definition at line 43 of file cpg_iterator.hpp.

◆ operator++() [2/2]

template<typename IntType >
counting_iterator tbb::counting_iterator< IntType >::operator++ ( int  )
inline

Definition at line 46 of file cpg_iterator.hpp.

◆ operator+=()

template<typename IntType >
counting_iterator & tbb::counting_iterator< IntType >::operator+= ( difference_type  forward)
inline

Definition at line 41 of file cpg_iterator.hpp.

◆ operator-() [1/2]

template<typename IntType >
difference_type tbb::counting_iterator< IntType >::operator- ( const counting_iterator< IntType > &  it) const
inline

Definition at line 39 of file cpg_iterator.hpp.

◆ operator-() [2/2]

template<typename IntType >
counting_iterator tbb::counting_iterator< IntType >::operator- ( difference_type  backward) const
inline

Definition at line 57 of file cpg_iterator.hpp.

Here is the call graph for this function:

◆ operator--() [1/2]

template<typename IntType >
counting_iterator & tbb::counting_iterator< IntType >::operator-- ( )
inline

Definition at line 44 of file cpg_iterator.hpp.

◆ operator--() [2/2]

template<typename IntType >
counting_iterator tbb::counting_iterator< IntType >::operator-- ( int  )
inline

Definition at line 51 of file cpg_iterator.hpp.

◆ operator-=()

template<typename IntType >
counting_iterator & tbb::counting_iterator< IntType >::operator-= ( difference_type  backward)
inline

Definition at line 42 of file cpg_iterator.hpp.

◆ operator<()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator< ( const counting_iterator< IntType > &  it) const
inline

Definition at line 63 of file cpg_iterator.hpp.

◆ operator<=()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator<= ( const counting_iterator< IntType > &  it) const
inline

Definition at line 65 of file cpg_iterator.hpp.

◆ operator==()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator== ( const counting_iterator< IntType > &  it) const
inline

Definition at line 61 of file cpg_iterator.hpp.

◆ operator>()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator> ( const counting_iterator< IntType > &  it) const
inline

Definition at line 64 of file cpg_iterator.hpp.

◆ operator>=()

template<typename IntType >
bool tbb::counting_iterator< IntType >::operator>= ( const counting_iterator< IntType > &  it) const
inline

Definition at line 66 of file cpg_iterator.hpp.

◆ operator[]()

template<typename IntType >
value_type tbb::counting_iterator< IntType >::operator[] ( difference_type  i) const
inline

Definition at line 37 of file cpg_iterator.hpp.

Friends And Related Function Documentation

◆ operator+

template<typename IntType >
counting_iterator operator+ ( difference_type  forward,
const counting_iterator< IntType >  it 
)
friend

Definition at line 59 of file cpg_iterator.hpp.


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