Open CASCADE Technology 7.8.2.dev
NCollection_Iterator< Container > Class Template Reference

Helper class that allows to use NCollection iterators as STL iterators. NCollection iterator can be extended to STL iterator of any category by adding necessary methods: STL forward iterator requires IsEqual method, STL bidirectional iterator requires Previous method, and STL random access iterator requires Offset and Differ methods. See NCollection_Vector as example of declaring custom STL iterators. More...

#include <NCollection_Iterator.hxx>

Inheritance diagram for NCollection_Iterator< Container >:

Public Member Functions

 NCollection_Iterator ()
 
 NCollection_Iterator (const NCollection_Iterator &theOther)
 
 NCollection_Iterator (const Container &theList)
 
 NCollection_Iterator (const Container &theList, const typename Container::iterator &theOther)
 
 NCollection_Iterator (const Container &theList, typename Container::iterator &&theOther)
 
 ~NCollection_Iterator ()
 
void Init (Container &theList)
 
void Init (const Container &theList)
 
virtual bool More () const
 
void Initialize (Container &theList)
 
void Initialize (const Container &theList)
 
const Container::iterator & ValueIter () const
 
Container::iterator & ChangeValueIter ()
 
const Container::iterator & EndIter () const
 
Container::iterator & ChangeEndIter ()
 
virtual void Next ()
 
const Container::const_reference Value () const
 
const Container::reference ChangeValue ()
 
bool operator== (const NCollection_Iterator &theOther)
 
bool operator!= (const NCollection_Iterator &theOther)
 
NCollection_Iteratoroperator= (const NCollection_Iterator &theOther)
 
NCollection_Iteratoroperator= (NCollection_Iterator &&theOther)
 

Detailed Description

template<class Container>
class NCollection_Iterator< Container >

Helper class that allows to use NCollection iterators as STL iterators. NCollection iterator can be extended to STL iterator of any category by adding necessary methods: STL forward iterator requires IsEqual method, STL bidirectional iterator requires Previous method, and STL random access iterator requires Offset and Differ methods. See NCollection_Vector as example of declaring custom STL iterators.

Constructor & Destructor Documentation

◆ NCollection_Iterator() [1/5]

template<class Container >
NCollection_Iterator< Container >::NCollection_Iterator ( )
inline

◆ NCollection_Iterator() [2/5]

template<class Container >
NCollection_Iterator< Container >::NCollection_Iterator ( const NCollection_Iterator< Container > & theOther)
inline

◆ NCollection_Iterator() [3/5]

template<class Container >
NCollection_Iterator< Container >::NCollection_Iterator ( const Container & theList)
inline

◆ NCollection_Iterator() [4/5]

template<class Container >
NCollection_Iterator< Container >::NCollection_Iterator ( const Container & theList,
const typename Container::iterator & theOther )
inline

◆ NCollection_Iterator() [5/5]

template<class Container >
NCollection_Iterator< Container >::NCollection_Iterator ( const Container & theList,
typename Container::iterator && theOther )
inline

◆ ~NCollection_Iterator()

template<class Container >
NCollection_Iterator< Container >::~NCollection_Iterator ( )
inline

Member Function Documentation

◆ ChangeEndIter()

template<class Container >
Container::iterator & NCollection_Iterator< Container >::ChangeEndIter ( )
inline

◆ ChangeValue()

template<class Container >
const Container::reference NCollection_Iterator< Container >::ChangeValue ( )
inline

◆ ChangeValueIter()

template<class Container >
Container::iterator & NCollection_Iterator< Container >::ChangeValueIter ( )
inline

◆ EndIter()

template<class Container >
const Container::iterator & NCollection_Iterator< Container >::EndIter ( ) const
inline

◆ Init() [1/2]

template<class Container >
void NCollection_Iterator< Container >::Init ( const Container & theList)
inline

◆ Init() [2/2]

template<class Container >
void NCollection_Iterator< Container >::Init ( Container & theList)
inline

◆ Initialize() [1/2]

template<class Container >
void NCollection_Iterator< Container >::Initialize ( const Container & theList)
inline

◆ Initialize() [2/2]

template<class Container >
void NCollection_Iterator< Container >::Initialize ( Container & theList)
inline

◆ More()

template<class Container >
virtual bool NCollection_Iterator< Container >::More ( ) const
inlinevirtual

◆ Next()

template<class Container >
virtual void NCollection_Iterator< Container >::Next ( )
inlinevirtual

◆ operator!=()

template<class Container >
bool NCollection_Iterator< Container >::operator!= ( const NCollection_Iterator< Container > & theOther)
inline

◆ operator=() [1/2]

template<class Container >
NCollection_Iterator & NCollection_Iterator< Container >::operator= ( const NCollection_Iterator< Container > & theOther)
inline

◆ operator=() [2/2]

template<class Container >
NCollection_Iterator & NCollection_Iterator< Container >::operator= ( NCollection_Iterator< Container > && theOther)
inline

◆ operator==()

template<class Container >
bool NCollection_Iterator< Container >::operator== ( const NCollection_Iterator< Container > & theOther)
inline

◆ Value()

template<class Container >
const Container::const_reference NCollection_Iterator< Container >::Value ( ) const
inline

◆ ValueIter()

template<class Container >
const Container::iterator & NCollection_Iterator< Container >::ValueIter ( ) const
inline

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