SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY > Class Template Reference

#include <source/patchdata/index/IndexData.h>

List of all members.

Public Member Functions

 IndexIterator ()
 IndexIterator (const IndexData< DIM, TYPE, BOX_GEOMETRY > &data)
 IndexIterator (const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &iterator)
IndexIterator< DIM, TYPE,
BOX_GEOMETRY > & 
operator= (const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &iterator)
 ~IndexIterator ()
TYPE & operator * ()
const TYPE & operator * () const
TYPE & operator() ()
const TYPE & operator() () const
TYPE & getItem ()
const hier::Index< DIM > & getIndex () const
 operator bool () const
 operator const void * () const
bool operator! () const
void operator++ (int)
void operator-- (int)
bool operator== (const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &iterator) const
bool operator!= (const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &iterator) const
void rewindIterator ()
void fastforwardIterator ()

Friends

class ConstIndexIterator< DIM, TYPE, BOX_GEOMETRY >
class IndexData< DIM, TYPE, BOX_GEOMETRY >


Detailed Description

template<int DIM, class TYPE, class BOX_GEOMETRY>
class SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >

Class IndexIterator is the iterator associated with the IndexData This class provides methods for stepping through the list that contains the irregular index set. The user should access this class through the name IndexData<DIM,TYPE>::Iterator.

This iterator should be used as follows:

   IndexData<DIM,TYPE> data;
   ...
   for (IndexData<DIM,TYPE>::Iterator iter(data); iter; iter++ {
      ... = iter();
   }
   

See also:
tbox::List

pdat::IndexData

pdat::IndexIterator


Constructor & Destructor Documentation

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::IndexIterator (  )  [inline]

Default constructor for the index list iterator. The iterator must be initialized before it can be used to iterate over an IndexData object.

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::IndexIterator ( const IndexData< DIM, TYPE, BOX_GEOMETRY > &  data  )  [inline]

Constructor for the index list iterator. The iterator will iterate over the irregular index set of the argument data object.

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::IndexIterator ( const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &  iterator  )  [inline]

Copy constructor for the index list iterator.

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::~IndexIterator (  )  [inline]

Destructor for the index list iterator.


Member Function Documentation

template<int DIM, class TYPE, class BOX_GEOMETRY>
IndexIterator< DIM, TYPE, BOX_GEOMETRY > & SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator= ( const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &  iterator  )  [inline]

Assignment operator for the index list iterator.

template<int DIM, class TYPE, class BOX_GEOMETRY>
TYPE & SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator * (  )  [inline]

Return the current item in the irregular index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
const TYPE & SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator * (  )  const [inline]

Return a const reference to the current item in the irregular index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
TYPE & SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator() (  )  [inline]

Return the current item in the irregular index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
const TYPE & SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator() (  )  const [inline]

Return a const refeferene to the current item in the irregular index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
TYPE& SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::getItem (  ) 

Return the current item in the irregular index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
const hier::Index<DIM>& SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::getIndex (  )  const

Return the index of the current item in the irregular index set

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator bool (  )  const [inline]

Return true if the iterator points to a valid item in the index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator const void * (  )  const [inline]

Return a non-null if the iterator points to a valid item in the index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
bool SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator! (  )  const [inline]

Return whether the iterator points to a valid item in the index set. This operator mimics the !p operation applied to a pointer p.

template<int DIM, class TYPE, class BOX_GEOMETRY>
void SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator++ ( int   )  [inline]

Increment the iterator to point to the next item in the index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
void SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator-- ( int   )  [inline]

Decrement the iterator to point to the previous item in the index set.

template<int DIM, class TYPE, class BOX_GEOMETRY>
bool SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator== ( const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &  iterator  )  const [inline]

Test two iterators for equality (pointing to the same item).

template<int DIM, class TYPE, class BOX_GEOMETRY>
bool SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::operator!= ( const IndexIterator< DIM, TYPE, BOX_GEOMETRY > &  iterator  )  const [inline]

Test two iterators for inequality (pointing to different items).

template<int DIM, class TYPE, class BOX_GEOMETRY>
void SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::rewindIterator (  )  [inline]

template<int DIM, class TYPE, class BOX_GEOMETRY>
void SAMRAI::pdat::IndexIterator< DIM, TYPE, BOX_GEOMETRY >::fastforwardIterator (  )  [inline]


Friends And Related Function Documentation

template<int DIM, class TYPE, class BOX_GEOMETRY>
friend class ConstIndexIterator< DIM, TYPE, BOX_GEOMETRY > [friend]

template<int DIM, class TYPE, class BOX_GEOMETRY>
friend class IndexData< DIM, TYPE, BOX_GEOMETRY > [friend]


The documentation for this class was generated from the following files:
Generated on Thu Jun 18 11:28:46 2009 for SAMRAI by  doxygen 1.5.1