AbstractTissue< DIM >::Iterator Class Reference

#include <AbstractTissue.hpp>

Collaboration diagram for AbstractTissue< DIM >::Iterator:

Collaboration graph
[legend]

List of all members.

Public Member Functions

TissueCelloperator* ()
TissueCelloperator-> ()
bool operator!= (const Iterator &other)
Iteratoroperator++ ()
 Iterator (AbstractTissue &rTissue, std::list< TissueCell >::iterator cellIter)
virtual ~Iterator ()

Private Member Functions

virtual bool IsRealCell ()
bool IsAtEnd ()

Private Attributes

AbstractTissuemrTissue
std::list< TissueCell >::iterator mCellIter


Detailed Description

template<unsigned DIM>
class AbstractTissue< DIM >::Iterator

Iterator class allows one to iterate over cells in the tissue. Dereferencing the iterator will give you the current cell. There are also methods to get the node representing this cell, and the location of that node.

Definition at line 494 of file AbstractTissue.hpp.


Constructor & Destructor Documentation

template<unsigned DIM>
AbstractTissue< DIM >::Iterator::Iterator ( AbstractTissue rTissue,
std::list< TissueCell >::iterator  cellIter 
) [inline]

Constructor for a new iterator.

Parameters:
rTissue the tissue
cellIter iterator over list of cells

Definition at line 645 of file AbstractTissue.hpp.

References AbstractTissue< DIM >::Iterator::IsRealCell(), AbstractTissue< DIM >::Iterator::mCellIter, AbstractTissue< DIM >::Iterator::mrTissue, and AbstractTissue< DIM >::rGetCells().

template<unsigned DIM>
virtual AbstractTissue< DIM >::Iterator::~Iterator (  )  [inline, virtual]

The iterator must have a virtual destructor.

Definition at line 532 of file AbstractTissue.hpp.


Member Function Documentation

template<unsigned DIM>
TissueCell & AbstractTissue< DIM >::Iterator::operator* (  )  [inline]

Dereference the iterator giving you a *reference* to the current cell. Make sure to use a reference for the result to avoid copying cells unnecessarily.

Definition at line 601 of file AbstractTissue.hpp.

References AbstractTissue< DIM >::Iterator::IsAtEnd(), and AbstractTissue< DIM >::Iterator::mCellIter.

template<unsigned DIM>
TissueCell * AbstractTissue< DIM >::Iterator::operator-> (  )  [inline]

Member access from a pointer.

Definition at line 608 of file AbstractTissue.hpp.

References AbstractTissue< DIM >::Iterator::IsAtEnd().

template<unsigned DIM>
bool AbstractTissue< DIM >::Iterator::operator!= ( const Iterator other  )  [inline]

Comparison not-equal-to.

Parameters:
other iterator with which comparison is made

template<unsigned DIM>
AbstractTissue< DIM >::Iterator & AbstractTissue< DIM >::Iterator::operator++ (  )  [inline]

template<unsigned DIM>
bool AbstractTissue< DIM >::Iterator::IsRealCell (  )  [inline, private, virtual]

Private helper function which tells us if we're pointing at a real cell. Assumes we are within range (i.e. not at End).

Real cells are not deleted.

Definition at line 633 of file AbstractTissue.hpp.

References AbstractTissue< DIM >::IsCellAssociatedWithADeletedNode(), AbstractTissue< DIM >::Iterator::mCellIter, and AbstractTissue< DIM >::Iterator::mrTissue.

Referenced by AbstractTissue< DIM >::Iterator::Iterator(), and AbstractTissue< DIM >::Iterator::operator++().

template<unsigned DIM>
bool AbstractTissue< DIM >::Iterator::IsAtEnd (  )  [inline, private]


Member Data Documentation

template<unsigned DIM>
AbstractTissue& AbstractTissue< DIM >::Iterator::mrTissue [private]

template<unsigned DIM>
std::list<TissueCell>::iterator AbstractTissue< DIM >::Iterator::mCellIter [private]


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

Generated on Wed Mar 18 12:52:13 2009 for Chaste by  doxygen 1.5.5