- Main Page
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# Mers::Utils::Containers::IConstantIterator Class Reference

`#include <Iterators.h>`

Inheritance diagram for Mers::Utils::Containers::IConstantIterator:

[legend]
List of all members.

## Public Member Functions
bool | operator== (const IConstantIterator &other) const
bool | operator!= (const IConstantIterator &other) const
## Protected Member Functions
| IConstantIterator (void const *myList=NULL, unsigned int myIndex=0)
| IConstantIterator (IConstantIterator const &other)
IConstantIterator & | operator= (const IConstantIterator &other)
IConstantIterator & | operator++ ()
IConstantIterator | operator++ (int)
IConstantIterator & | operator-- ()
IConstantIterator | operator-- (int)
IConstantIterator & | operator+= (int ival)
IConstantIterator & | operator-= (int ival)
## Protected Attributes
void const * | m_List
unsigned int | m_Index
| index of this object into the iterating object

## Detailed Description

This class provides generic constant iterator functionality

Definition at line 34 of file Iterators.h.

## Constructor & Destructor Documentation

IConstantIterator::IConstantIterator | ( | void const * | myList = `NULL`,
|  | unsigned int | myIndex = `0` |
| ) |  |  | `[protected]`

creates a new constant iterator on the specified list with the specified starting index

Parameters:

  | myList | the array that this iterator will iterate through
  | myIndex | the starting index of this iterator

Definition at line 41 of file Iterators.cpp.

References m_Index.

IConstantIterator::IConstantIterator | ( | IConstantIterator const & | other | ) | `[protected]`

Copy constructor for this object that constructs using the parent class

Parameters:

  | other | the constant iterator that this object should copy from

Definition at line 49 of file Iterators.cpp.

References m_Index.

## Member Function Documentation

bool IConstantIterator::operator== | ( | const IConstantIterator & | other | ) | const

Returns true if the two iterators point to the same data.

Parameters:

  | other | the other object being compared to this object.

Returns:
  true if the iterators are the same.

Definition at line 27 of file Iterators.cpp.

References m_Index, and m_List.

Referenced by operator!=(), and Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >::operator==().

bool IConstantIterator::operator!= | ( | const IConstantIterator & | other | ) | const

Returns false if the two iterators point to the same data.

Parameters:

  | other | the other object being compared to this object.

Returns:
  true if the iterators are different.

Definition at line 34 of file Iterators.cpp.

References operator==().

Referenced by Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >::operator!=().

Here is the call graph for this function:

IConstantIterator & IConstantIterator::operator= | ( | const IConstantIterator & | other | ) | `[protected]`

copies the iterator position and object from the other iterator

Parameters:

  | other | the other iterator that this object will be copied from

Returns:
  a reference to this iterator

Definition at line 58 of file Iterators.cpp.

References m_Index, and m_List.

Referenced by Mers::Utils::Containers::IIterator::operator=().

IConstantIterator& Mers::Utils::Containers::IConstantIterator::operator++ | ( |  | ) | `[inline, protected]`

increments this iterator to point to the next element in the array

Returns:
  a reference to this object, which points to the next element

Reimplemented in Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >.

Definition at line 93 of file Iterators.h.

References m_Index.

Referenced by operator++().

IConstantIterator Mers::Utils::Containers::IConstantIterator::operator++ | ( | int |  | ) | `[inline, protected]`

post-increments this iterator to point to the next element in the array

Returns:
  a copy of the iterator, which points to the element prior to incrementing

Reimplemented in Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >.

Definition at line 105 of file Iterators.h.

References operator++().

Here is the call graph for this function:

IConstantIterator& Mers::Utils::Containers::IConstantIterator::operator-- | ( |  | ) | `[inline, protected]`

decrements this iterator to point to the previous element in the array

Returns:
  a reference to this object, which points to the previous element

Reimplemented in Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >.

Definition at line 118 of file Iterators.h.

References m_Index.

Referenced by operator--().

IConstantIterator Mers::Utils::Containers::IConstantIterator::operator-- | ( | int |  | ) | `[inline, protected]`

post-decrements this iterator to point to the previous element in the array

Returns:
  a copy of the iterator, which points to the element prior to decrementing

Reimplemented in Mers::Utils::Containers::IteratorTemplate< t_Iterand, t_Container >.

Definition at line 131 of file Iterators.h.

References operator--().

Here is the call graph for this function:

IConstantIterator & IConstantIterator::operator+= | ( | int | ival | ) | `[protected]`

Increments the iterator by the specified amount.

Parameters:

  | ival | The offset to add to the current index.

Definition at line 69 of file Iterators.cpp.

References m_Index.

IConstantIterator & IConstantIterator::operator-= | ( | int | ival | ) | `[protected]`

Decrements the iterator by the specified amount.

Parameters:

  | ival | The offset to subtract from the current index.

Definition at line 82 of file Iterators.cpp.

References m_Index.

## Member Data Documentation

void const* Mers::Utils::Containers::IConstantIterator::m_List`[protected]`

pointer to the array or other object that we're iterating through

Reimplemented in Mers::Utils::Containers::IIterator.

Definition at line 154 of file Iterators.h.

Referenced by operator=(), and operator==().

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

- /Users/fpy/titan-1-5-MBARI/Mers/Utils/Containers/Iterators.h
- /Users/fpy/titan-1-5-MBARI/Mers/Utils/Containers/Iterators.cpp