gatb.core-API-1.4.2
IteratorAdaptor< T1, T2, Adaptor > Class Template Reference

Iterator adaptation from one type to another one. More...

#include <IteratorHelpers.hpp>

Inheritance diagram for IteratorAdaptor< T1, T2, Adaptor >:
Inheritance graph

Public Member Functions

 IteratorAdaptor (Iterator< T1 > *ref)
 
 ~IteratorAdaptor ()
 
void first ()
 
void next ()
 
bool isDone ()
 
T2 & item ()
 
- Public Member Functions inherited from Iterator< T2 >
T2 * operator-> ()
 
T2 & operator* ()
 
void iterate (const Functor &f)
 
virtual void setItem (T2 &i)
 
bool get (std::vector< T2 > &current)
 
virtual void reset ()
 
virtual void finalize ()
 
virtual std::vector< Iterator< T2 > * > getComposition ()
 
- Public Member Functions inherited from SmartPointer
void use ()
 
void forget ()
 
- Public Member Functions inherited from ISmartPointer
virtual ~ISmartPointer ()
 

Additional Inherited Members

- Protected Member Functions inherited from SmartPointer
 SmartPointer ()
 
virtual ~SmartPointer ()
 

Detailed Description

template<class T1, class T2, class Adaptor>
class gatb::core::tools::dp::impl::IteratorAdaptor< T1, T2, Adaptor >

Iterator adaptation from one type to another one.

Constructor & Destructor Documentation

IteratorAdaptor ( Iterator< T1 > *  ref)
inline

Constructor.

~IteratorAdaptor ( )
inline

Destructor.

Member Function Documentation

void first ( )
inlinevirtual

Method that initializes the iteration.

Implements Iterator< T2 >.

bool isDone ( )
inlinevirtual

Method telling whether the iteration is finished or not.

Returns
true if iteration is finished, false otherwise.

Implements Iterator< T2 >.

T2& item ( )
inlinevirtual

Method that returns the current iterated item. Note that the returned type is the template type.

Returns
the current item in the iteration.

Implements Iterator< T2 >.

void next ( )
inlinevirtual

Method that goes to the next item in the iteration.

Returns
status of the iteration

Implements Iterator< T2 >.


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