gatb.core-API-0.0.0
IteratorFile< Item > Class Template Reference

Iterator implementation for file. More...

#include <IteratorFile.hpp>

Inheritance diagram for IteratorFile< Item >:
Inheritance graph

Public Member Functions

 IteratorFile ()
 
 IteratorFile (const std::string &filename, size_t cacheItemsNb=10000)
 
 ~IteratorFile ()
 
IteratorFileoperator= (const IteratorFile &it)
 
void first ()
 
void next ()
 
bool isDone ()
 
Item & item ()
 
- Public Member Functions inherited from Iterator< Item >
Item * operator-> ()
 
Item & operator* ()
 
template<typename Functor >
void iterate (const Functor &f)
 
virtual void setItem (Item &i)
 
bool get (std::vector< Item > &current)
 
virtual void reset ()
 
virtual void finalize ()
 
virtual std::vector< Iterator< Item > * > 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 Item>
class gatb::core::tools::collections::impl::IteratorFile< Item >

Iterator implementation for file.

Constructor & Destructor Documentation

IteratorFile ( )
inline

Constructor.

IteratorFile ( const std::string &  filename,
size_t  cacheItemsNb = 10000 
)
inline

Constructor.

~IteratorFile ( )
inline

Destructor.

Member Function Documentation

void first ( )
inlinevirtual

Method that initializes the iteration.

Implements Iterator< Item >.

bool isDone ( )
inlinevirtual

Method telling whether the iteration is finished or not.

Returns
true if iteration is finished, false otherwise.

Implements Iterator< Item >.

Item& 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< Item >.

void next ( )
inlinevirtual

Method that goes to the next item in the iteration.

Returns
status of the iteration

Implements Iterator< Item >.

IteratorFile& operator= ( const IteratorFile< Item > &  it)
inline

Affectation.


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