Public Types | Public Member Functions | Private Types | List of all members
util::details::infinite_endcount_iterator< T > Class Template Reference

Class used as end iterator (sentinel) for an infinite loop. More...

#include <counter.h>

Public Types

using value_type = T
 
using reference = T const &
 
using pointer = T const *
 
using difference_type = std::ptrdiff_t
 
using iterator_category = std::forward_iterator_tag
 

Public Member Functions

bool operator== (this_iterator_t const &) const
 Never admit this iterator is equal to anything else (except the same). More...
 
bool operator!= (this_iterator_t const &) const
 Never admit this iterator is equal to anything else (except the same). More...
 

Private Types

using this_iterator_t = infinite_endcount_iterator< T >
 
using count_iterator_t = count_iterator< T >
 

Detailed Description

template<typename T>
class util::details::infinite_endcount_iterator< T >

Class used as end iterator (sentinel) for an infinite loop.

Template Parameters
Tthe nominal count type

This "iterator" offers a very limited interface, not at all like a real iterator. In fact, it can only be compared to other count_iterator objects on the same counter type.

Definition at line 234 of file counter.h.

Member Typedef Documentation

template<typename T >
using util::details::infinite_endcount_iterator< T >::count_iterator_t = count_iterator<T>
private

Definition at line 236 of file counter.h.

template<typename T >
using util::details::infinite_endcount_iterator< T >::difference_type = std::ptrdiff_t

Definition at line 244 of file counter.h.

template<typename T >
using util::details::infinite_endcount_iterator< T >::iterator_category = std::forward_iterator_tag

Definition at line 245 of file counter.h.

template<typename T >
using util::details::infinite_endcount_iterator< T >::pointer = T const*

Definition at line 243 of file counter.h.

template<typename T >
using util::details::infinite_endcount_iterator< T >::reference = T const&

Definition at line 242 of file counter.h.

Definition at line 235 of file counter.h.

template<typename T >
using util::details::infinite_endcount_iterator< T >::value_type = T

Definition at line 241 of file counter.h.

Member Function Documentation

template<typename T >
bool util::details::infinite_endcount_iterator< T >::operator!= ( this_iterator_t const &  ) const
inline

Never admit this iterator is equal to anything else (except the same).

Definition at line 252 of file counter.h.

252 { return false; }
template<typename T >
bool util::details::infinite_endcount_iterator< T >::operator== ( this_iterator_t const &  ) const
inline

Never admit this iterator is equal to anything else (except the same).

Definition at line 249 of file counter.h.

249 { return true; }

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