MDSTk Libraries  1.1.0
Medical Data Segmentation Toolkit
Public Types | Public Member Functions | Protected Attributes
mds::img::CVolumeIterator< V, T > Class Template Reference

Iterator used to traverse volume by lines. More...

#include <mdsVolumeIterator.h>

Inheritance diagram for mds::img::CVolumeIterator< V, T >:
Inheritance graph
[legend]

List of all members.

Public Types

enum  { TEMPLATE_PARAMETER_IS_NOT_VOLUME = V::CLASS_VOLUME }
 Check that type V is a volume. More...
typedef CVolumeIterator< V, T > tDerived
 Iterator type.
typedef CIteratorTraits
< CVolumeIterator< V, T >
>::tItem 
tItem
 Value (or item) type.
typedef V tVolume
 Volume type.
typedef T tVoxel
 Voxel type.

Public Member Functions

void advance ()
 Moves iterator to the next voxel.
bool atEnd () const
 Returns true if the iterator points after the end.
 CVolumeIterator (tVolume &Volume)
 Constructor.
tDerivedgetImpl ()
 Returns reference to the iterator implementation.
const tDerivedgetImpl () const
tSize getSize () const
 Returns size of the volume in voxels.
 operator bool () const
 Returns true if the iterator is valid, i.e. not pointing after the end.
tItemoperator* () const
 Returns reference to the current item.
CIteratorBaseoperator++ ()
CIteratorBase operator++ (int)
tItemoperator-> () const
 Returns pointer to the current item.
const tVoxelvalue () const
 Returns the current voxel.
tVoxelvaluePtr () const
 Returns pointer to the current voxel.
tVoxelvalueRef () const
 Returns reference to the current voxel.
tSize x () const
 Returns the current iterator position.
tSize y () const
tSize z () const
 ~CVolumeIterator ()
 Destructor.

Protected Attributes

tVolumem_Volume
 Reference to the volume.
tSize m_x
 Iterator position.
tSize m_y
tSize m_z

Detailed Description

template<class V, typename T>
class mds::img::CVolumeIterator< V, T >

Iterator used to traverse volume by lines.


Member Typedef Documentation

typedef CVolumeIterator< V, T > mds::base::CIteratorBase< CVolumeIterator< V, T > >::tDerived [inherited]

Iterator type.

Value (or item) type.

template<class V , typename T >
typedef V mds::img::CVolumeIterator< V, T >::tVolume

Volume type.

template<class V , typename T >
typedef T mds::img::CVolumeIterator< V, T >::tVoxel

Voxel type.


Member Enumeration Documentation

template<class V , typename T >
anonymous enum

Check that type V is a volume.

You will see name of this enum somewhere in compiler error message if the type V is not volume.

Enumerator:
TEMPLATE_PARAMETER_IS_NOT_VOLUME 

Constructor & Destructor Documentation

template<class V , typename T >
mds::img::CVolumeIterator< V, T >::CVolumeIterator ( tVolume Volume)

Constructor.

template<class V , typename T >
mds::img::CVolumeIterator< V, T >::~CVolumeIterator ( )

Destructor.


Member Function Documentation

template<class V , typename T >
void mds::img::CVolumeIterator< V, T >::advance ( )

Moves iterator to the next voxel.

template<class V , typename T >
bool mds::img::CVolumeIterator< V, T >::atEnd ( ) const

Returns true if the iterator points after the end.

Returns reference to the iterator implementation.

const tDerived& mds::base::CIteratorBase< CVolumeIterator< V, T > >::getImpl ( ) const [inherited]
template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::getSize ( ) const

Returns size of the volume in voxels.

Reimplemented from mds::base::CIteratorBase< CVolumeIterator< V, T > >.

mds::base::CIteratorBase< CVolumeIterator< V, T > >::operator bool ( ) const [inherited]

Returns true if the iterator is valid, i.e. not pointing after the end.

tItem& mds::base::CIteratorBase< CVolumeIterator< V, T > >::operator* ( ) const [inherited]

Returns reference to the current item.

CIteratorBase& mds::base::CIteratorBase< CVolumeIterator< V, T > >::operator++ ( ) [inherited]
CIteratorBase mds::base::CIteratorBase< CVolumeIterator< V, T > >::operator++ ( int  ) [inherited]
tItem* mds::base::CIteratorBase< CVolumeIterator< V, T > >::operator-> ( ) const [inherited]

Returns pointer to the current item.

template<class V , typename T >
const tVoxel& mds::img::CVolumeIterator< V, T >::value ( ) const

Returns the current voxel.

Reimplemented from mds::base::CIteratorBase< CVolumeIterator< V, T > >.

template<class V , typename T >
tVoxel* mds::img::CVolumeIterator< V, T >::valuePtr ( ) const

Returns pointer to the current voxel.

Reimplemented from mds::base::CIteratorBase< CVolumeIterator< V, T > >.

template<class V , typename T >
tVoxel& mds::img::CVolumeIterator< V, T >::valueRef ( ) const

Returns reference to the current voxel.

Reimplemented from mds::base::CIteratorBase< CVolumeIterator< V, T > >.

template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::x ( ) const

Returns the current iterator position.

template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::y ( ) const
template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::z ( ) const

Member Data Documentation

template<class V , typename T >
tVolume& mds::img::CVolumeIterator< V, T >::m_Volume [protected]

Reference to the volume.

template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::m_x [protected]

Iterator position.

template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::m_y [protected]
template<class V , typename T >
tSize mds::img::CVolumeIterator< V, T >::m_z [protected]

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