IntRange< IntType >::const_iterator Class Reference

Random-access input iterator with const access. More...

Public Types

typedef std::random_access_iterator_tag iterator_category
 
typedef IntType value_type
 
typedef IntType difference_type
 
typedef const IntType * pointer
 
typedef IntType reference
 

Public Member Functions

constexpr const_iterator (IntType val=0) noexcept
 Construct with specified value, or default construct. More...
 
constexpr IntType operator* () const noexcept
 Return the value. More...
 
constexpr IntType operator[] (const IntType n) const noexcept
 Offset dereference operator. More...
 
const_iteratoroperator++ () noexcept
 Prefix increment. More...
 
const_iterator operator++ (int) noexcept
 Postfix increment. More...
 
const_iteratoroperator-- () noexcept
 Prefix decrement. More...
 
const_iterator operator-- (int) noexcept
 Postfix decrement. More...
 
const_iteratoroperator+= (const IntType n) noexcept
 Arbitrary increment. More...
 
const_iteratoroperator-= (const IntType n) noexcept
 Arbitrary decrement. More...
 
constexpr const_iterator operator+ (const IntType n) const noexcept
 Return iterator with offset. More...
 
constexpr const_iterator operator- (const IntType n) const noexcept
 Return iterator with offset. More...
 
constexpr IntType operator- (const const_iterator &iter) const noexcept
 Difference operator. More...
 
constexpr bool operator== (const const_iterator &iter) const noexcept
 Test for equality of values. More...
 
constexpr bool operator< (const const_iterator &iter) const noexcept
 Compare less-than. More...
 
constexpr bool operator!= (const const_iterator &iter) const noexcept
 
constexpr bool operator<= (const const_iterator &iter) const noexcept
 
constexpr bool operator> (const const_iterator &iter) const noexcept
 
constexpr bool operator>= (const const_iterator &iter) const noexcept
 

Detailed Description

template<class IntType>
class Foam::IntRange< IntType >::const_iterator

Random-access input iterator with const access.

Note
No operator+(IntType, iterator) since this provokes misleading resolution errors

Definition at line 357 of file IntRange.H.

Member Typedef Documentation

◆ iterator_category

typedef std::random_access_iterator_tag iterator_category

Definition at line 367 of file IntRange.H.

◆ value_type

typedef IntType value_type

Definition at line 368 of file IntRange.H.

◆ difference_type

typedef IntType difference_type

Definition at line 369 of file IntRange.H.

◆ pointer

typedef const IntType* pointer

Definition at line 370 of file IntRange.H.

◆ reference

typedef IntType reference

Definition at line 371 of file IntRange.H.

Constructor & Destructor Documentation

◆ const_iterator()

constexpr const_iterator ( IntType  val = 0)
inlineexplicitnoexcept

Construct with specified value, or default construct.

Definition at line 379 of file IntRange.H.

Member Function Documentation

◆ operator*()

constexpr IntType operator* ( ) const
inlinenoexcept

Return the value.

Definition at line 390 of file IntRange.H.

◆ operator[]()

constexpr IntType operator[] ( const IntType  n) const
inlinenoexcept

Offset dereference operator.

Definition at line 89 of file IntRangeI.H.

References n.

◆ operator++() [1/2]

Foam::IntRange< IntType >::const_iterator & operator++ ( )
inlinenoexcept

Prefix increment.

Definition at line 98 of file IntRangeI.H.

◆ operator++() [2/2]

Foam::IntRange< IntType >::const_iterator operator++ ( int  )
inlinenoexcept

Postfix increment.

Definition at line 108 of file IntRangeI.H.

◆ operator--() [1/2]

Foam::IntRange< IntType >::const_iterator & operator-- ( )
inlinenoexcept

Prefix decrement.

Definition at line 119 of file IntRangeI.H.

◆ operator--() [2/2]

Foam::IntRange< IntType >::const_iterator operator-- ( int  )
inlinenoexcept

Postfix decrement.

Definition at line 129 of file IntRangeI.H.

◆ operator+=()

Foam::IntRange< IntType >::const_iterator & operator+= ( const IntType  n)
inlinenoexcept

Arbitrary increment.

Definition at line 140 of file IntRangeI.H.

References n.

◆ operator-=()

Foam::IntRange< IntType >::const_iterator & operator-= ( const IntType  n)
inlinenoexcept

Arbitrary decrement.

Definition at line 150 of file IntRangeI.H.

References n.

◆ operator+()

constexpr Foam::IntRange< IntType >::const_iterator operator+ ( const IntType  n) const
inlinenoexcept

Return iterator with offset.

Definition at line 160 of file IntRangeI.H.

References n.

◆ operator-() [1/2]

constexpr Foam::IntRange< IntType >::const_iterator operator- ( const IntType  n) const
inlinenoexcept

Return iterator with offset.

Definition at line 169 of file IntRangeI.H.

References n.

◆ operator-() [2/2]

constexpr IntType operator- ( const const_iterator iter) const
inlinenoexcept

Difference operator.

Definition at line 178 of file IntRangeI.H.

◆ operator==()

constexpr bool operator== ( const const_iterator iter) const
inlinenoexcept

Test for equality of values.

Definition at line 187 of file IntRangeI.H.

◆ operator<()

constexpr bool operator< ( const const_iterator iter) const
inlinenoexcept

Compare less-than.

Definition at line 196 of file IntRangeI.H.

◆ operator!=()

constexpr bool operator!= ( const const_iterator iter) const
inlinenoexcept

Definition at line 469 of file IntRange.H.

◆ operator<=()

constexpr bool operator<= ( const const_iterator iter) const
inlinenoexcept

Definition at line 475 of file IntRange.H.

◆ operator>()

constexpr bool operator> ( const const_iterator iter) const
inlinenoexcept

Definition at line 481 of file IntRange.H.

◆ operator>=()

constexpr bool operator>= ( const const_iterator iter) const
inlinenoexcept

Definition at line 487 of file IntRange.H.


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