Base Framework
Public Types | Public Member Functions | List of all members
AllocatorEnumerator< TRAITS > Class Template Reference

Enumerator of elements of a sequence. More...

#include <base/mem/AllocatorEnumeration.h>

Inherits Enumerator< TRAITS >.

Public Types

typedef Enumerator< TRAITS >::Value Value
 
typedef Enumerator< TRAITS >::Reference Reference
 
typedef Enumerator< TRAITS >::Pointer Pointer
 
- Public Types inherited from Enumerator< TRAITS >
typedef TRAITS::Value Value
 
typedef TRAITS::Distance Distance
 
typedef TRAITS::Reference Reference
 
typedef TRAITS::Pointer Pointer
 

Public Member Functions

 AllocatorEnumerator (Pointer begin, Pointer _end) noexcept
 
 AllocatorEnumerator (const AllocatorEnumerator &copy) noexcept
 
bool hasNext () const noexcept
 
Reference next ()
 
bool operator== (const AllocatorEnumerator &compare) const noexcept
 
bool operator!= (const AllocatorEnumerator &compare) const noexcept
 
- Public Member Functions inherited from Enumerator< TRAITS >
virtual ~Enumerator ()
 

Detailed Description

template<class TRAITS>
class AllocatorEnumerator< TRAITS >

Enumerator of elements of a sequence.

Enumerator used to traverse elements of a sequence (not to be confused with the Array collection).

Version
1.0
Examples
testsuite/IEEE1394.cpp.

Constructor & Destructor Documentation

◆ AllocatorEnumerator() [1/2]

template<class TRAITS >
AllocatorEnumerator< TRAITS >::AllocatorEnumerator ( Pointer  begin,
Pointer  _end 
)
inlinenoexcept

Initializes an enumeration of all the elements specified by 'begin' and 'end'.

Parameters
beginSpecifies the beginning of the enumeration.
endSpecifies the end of the enumeration.

◆ AllocatorEnumerator() [2/2]

template<class TRAITS >
AllocatorEnumerator< TRAITS >::AllocatorEnumerator ( const AllocatorEnumerator< TRAITS > &  copy)
inlinenoexcept

Initializes enumeration from other enumeration.

Member Function Documentation

◆ hasNext()

template<class TRAITS >
bool AllocatorEnumerator< TRAITS >::hasNext ( ) const
inlinevirtualnoexcept

Returns true if the enumeration still contains elements.

Implements Enumerator< TRAITS >.

Examples
testsuite/IEEE1394.cpp.

◆ next()

template<class TRAITS >
Reference AllocatorEnumerator< TRAITS >::next ( )
inlinevirtual

Returns the next element and advances the position of this enumeration.

Implements Enumerator< TRAITS >.

Examples
testsuite/IEEE1394.cpp.

◆ operator!=()

template<class TRAITS >
bool AllocatorEnumerator< TRAITS >::operator!= ( const AllocatorEnumerator< TRAITS > &  compare) const
inlinenoexcept

Returns true if the enumerations are not referencing the same element.

◆ operator==()

template<class TRAITS >
bool AllocatorEnumerator< TRAITS >::operator== ( const AllocatorEnumerator< TRAITS > &  compare) const
inlinenoexcept

Returns true if the enumerations are referencing the same element.