concepts::StlVectorScan< T, ItType > Class Template Reference

Scanner working on std::vector elements. More...

#include <scannerConnectors.hh>

Inheritance diagram for concepts::StlVectorScan< T, ItType >:
concepts::Scan< T >

Public Member Functions

StlVectorScanclone () const
 Returns a clone of the scanner. More...
 
bool eos () const
 Returns true if the end of the scanned set is reached. More...
 
 operator int ()
 Returns true as long as the end of the scanned set is not reached yet. More...
 
T & operator* ()
 
T & operator++ ()
 pre-increment operator More...
 
T & operator++ (int)
 post-increment operator More...
 
 StlVectorScan (const Vector &vec, ItType it)
 Constructor. More...
 
 StlVectorScan (Vector &vec)
 Constructor. More...
 

Private Types

typedef std::vector< T * > Vector
 

Private Attributes

ItType it
 
const Vectorvec
 

Detailed Description

template<class T, class ItType = typename std::vector<T*>::const_iterator>
class concepts::StlVectorScan< T, ItType >

Scanner working on std::vector elements.

ItType should be std::vector<T>::iterator or std::vector<T>::const_iterator.

Author
Holger Brandsmeier, 2009

Definition at line 281 of file scannerConnectors.hh.

Member Typedef Documentation

◆ Vector

template<class T , class ItType = typename std::vector<T*>::const_iterator>
typedef std::vector<T*> concepts::StlVectorScan< T, ItType >::Vector
private

Definition at line 282 of file scannerConnectors.hh.

Constructor & Destructor Documentation

◆ StlVectorScan() [1/2]

template<class T , class ItType = typename std::vector<T*>::const_iterator>
concepts::StlVectorScan< T, ItType >::StlVectorScan ( const Vector vec,
ItType  it 
)
inline

Constructor.

Parameters
vecthe vector to reference over, needed for checking of eof
itthe initial iterator

Definition at line 293 of file scannerConnectors.hh.

◆ StlVectorScan() [2/2]

template<class T , class ItType = typename std::vector<T*>::const_iterator>
concepts::StlVectorScan< T, ItType >::StlVectorScan ( Vector vec)
inline

Constructor.

Parameters
vecthe vector to reference over, needed for checking of eof

Definition at line 300 of file scannerConnectors.hh.

Member Function Documentation

◆ clone()

template<class T , class ItType = typename std::vector<T*>::const_iterator>
StlVectorScan* concepts::StlVectorScan< T, ItType >::clone ( ) const
inlinevirtual

Returns a clone of the scanner.

Implements concepts::Scan< T >.

Definition at line 306 of file scannerConnectors.hh.

◆ eos()

template<class T , class ItType = typename std::vector<T*>::const_iterator>
bool concepts::StlVectorScan< T, ItType >::eos ( ) const
inlinevirtual

Returns true if the end of the scanned set is reached.

Implements concepts::Scan< T >.

Definition at line 304 of file scannerConnectors.hh.

◆ operator int()

template<class T >
concepts::Scan< T >::operator int ( )
inlineinherited

Returns true as long as the end of the scanned set is not reached yet.

Definition at line 34 of file scannerConnectors.hh.

◆ operator*()

template<class T , class ItType = typename std::vector<T*>::const_iterator>
T& concepts::StlVectorScan< T, ItType >::operator* ( )
inline

Definition at line 308 of file scannerConnectors.hh.

◆ operator++() [1/2]

template<class T , class ItType = typename std::vector<T*>::const_iterator>
T& concepts::StlVectorScan< T, ItType >::operator++ ( )
inline

pre-increment operator

Definition at line 320 of file scannerConnectors.hh.

◆ operator++() [2/2]

template<class T , class ItType = typename std::vector<T*>::const_iterator>
T& concepts::StlVectorScan< T, ItType >::operator++ ( int  )
inlinevirtual

post-increment operator

Implements concepts::Scan< T >.

Definition at line 313 of file scannerConnectors.hh.

Member Data Documentation

◆ it

template<class T , class ItType = typename std::vector<T*>::const_iterator>
ItType concepts::StlVectorScan< T, ItType >::it
private

Definition at line 285 of file scannerConnectors.hh.

◆ vec

template<class T , class ItType = typename std::vector<T*>::const_iterator>
const Vector& concepts::StlVectorScan< T, ItType >::vec
private

Definition at line 284 of file scannerConnectors.hh.


The documentation for this class was generated from the following file:
Page URL: http://wiki.math.ethz.ch/bin/view/Concepts/WebHome
21 August 2020
© 2020 Eidgenössische Technische Hochschule Zürich