Michele De Stefano's C++ Utilities
mds_utils::python::PySequenceIterator< T, Reference > Class Template Reference

Iterator that allows to scan a Python sequence composed by homogeneous elements. More...

#include <mds_utils/python/sequence_iterator.hpp>

Inheritance diagram for mds_utils::python::PySequenceIterator< T, Reference >:

Public Member Functions

 PySequenceIterator ()
 Default constructor. More...
 
 PySequenceIterator (PyObject *o, bool end=false)
 Constructor that builds the start or the Past-the-end iterator. More...
 
 PySequenceIterator (const PySequenceIterator &rhs)
 The copy constructor.
 
 ~PySequenceIterator ()
 Destructor.
 
PySequenceIteratoroperator= (const PySequenceIterator &rhs)
 Assignment.
 

Friends

class boost::iterator_core_access
 
class PySeqIt_Access< PySequenceIterator< T, Reference > >
 

Detailed Description

template<class T, class Reference>
class mds_utils::python::PySequenceIterator< T, Reference >

Iterator that allows to scan a Python sequence composed by homogeneous elements.

It can be also used to modify sequence values.

Template Parameters
TThe iterator's value_type.
ReferenceIt's a proxy class that is returned by the dereference method. It manages the return value and the assignment of a value.
Remarks
It models the Bidirectional Iterator Concept.
Author
Michele De Stefano
Date
02/10/2012

Definition at line 165 of file sequence_iterator.hpp.

Constructor & Destructor Documentation

template<class T, class Reference>
mds_utils::python::PySequenceIterator< T, Reference >::PySequenceIterator ( )
inline

Default constructor.

It builds an unusable iterator.

Author
Michele De Stefano
Date
24/09/2012

Definition at line 215 of file sequence_iterator.hpp.

template<class T, class Reference>
mds_utils::python::PySequenceIterator< T, Reference >::PySequenceIterator ( PyObject *  o,
bool  end = false 
)
inline

Constructor that builds the start or the Past-the-end iterator.

Parameters
oThe Python object representing a sequence.
endIf true, it will build the Past-the-end iterator. If false (default) it builds the start iterator.
Author
Michele De Stefano
Date
24/09/2012

Definition at line 231 of file sequence_iterator.hpp.


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