Loading...
Searching...
No Matches
EST_TIterator< Container, IPointer, Entry > Class Template Reference
Inheritance diagram for EST_TIterator< Container, IPointer, Entry >:
[legend]
Collaboration diagram for EST_TIterator< Container, IPointer, Entry >:
[legend]

## Public Types

typedef EST_TIterator< Container, IPointer, Entry > | Iter
| Name for an iterator like this.

## Public Member Functions

| EST_TIterator ()
| Create an iterator not associated with any specific container.
| EST_TIterator (const Container &over)
| Create an iterator ready to run over the given container.
Iter & | operator= (const Iter &orig)
| Copy an iterator by assignment.
Iter & | operator= (const Container &over)
| Assigning a container to an iterator sets it ready to start.
void | begin (const Container &over)
| Set the iterator ready to run over this container.
void | beginning ()
| Reset to the start of the container.
End Tests
bool | has_more_elements () const
| True if there are more elements to look at.
bool | at_end () const
| True when there are no more.
| operator int () const
Moving Forward
void | next ()
| Next moves to the next entry.
Iter & | operator++ ()
| The increment operator does the same as next.
Iter | operator++ (int dummy)

## Protected Attributes

Container * | cont
| The container we are looking at.
unsigned int | pos
| Position in the structure. May or may not be useful.
IPointer | pointer

## Access

class | EST_TStructIterator< Container, IPointer, Entry >
class | EST_TRwIterator< Container, IPointer, Entry >
class | EST_TRwStructIterator< Container, IPointer, Entry >
const Entry & | current () const
| Return the element currently pointed to.
const Entry & | operator* () const
| The * operator returns the current element.
const Entry & | next_element ()
| Return the current element and move the pointer forwards.
unsigned int | n () const
| Return the current position.

## Detailed Description

template<class Container, class IPointer, class Entry>
class EST_TIterator< Container, IPointer, Entry >

Definition at line 81 of file EST_TIterator.h.

## Member Typedef Documentation

## Iter

template<class Container, class IPointer, class Entry>

typedef EST_TIterator<Container, IPointer, Entry> EST_TIterator< Container, IPointer, Entry >::Iter

Name for an iterator like this.

Definition at line 97 of file EST_TIterator.h.

## Constructor & Destructor Documentation

## EST_TIterator() [1/2]

template<class Container, class IPointer, class Entry>

EST_TIterator< Container, IPointer, Entry >::EST_TIterator | ( |  | ) |

inline

Create an iterator not associated with any specific container.

Definition at line 100 of file EST_TIterator.h.

## EST_TIterator() [2/2]

template<class Container, class IPointer, class Entry>

EST_TIterator< Container, IPointer, Entry >::EST_TIterator | ( | const Container & | over | ) |

inline

Create an iterator ready to run over the given container.

Definition at line 103 of file EST_TIterator.h.

## Member Function Documentation

## operator=() [1/2]

template<class Container, class IPointer, class Entry>

Iter & EST_TIterator< Container, IPointer, Entry >::operator= | ( | const Iter & | orig | ) |

inline

Copy an iterator by assignment.

Definition at line 107 of file EST_TIterator.h.

## operator=() [2/2]

template<class Container, class IPointer, class Entry>

Iter & EST_TIterator< Container, IPointer, Entry >::operator= | ( | const Container & | over | ) |

inline

Assigning a container to an iterator sets it ready to start.

Definition at line 111 of file EST_TIterator.h.

## begin()

template<class Container, class IPointer, class Entry>

void EST_TIterator< Container, IPointer, Entry >::begin | ( | const Container & | over | ) |

inline

Set the iterator ready to run over this container.

Definition at line 115 of file EST_TIterator.h.

## beginning()

template<class Container, class IPointer, class Entry>

void EST_TIterator< Container, IPointer, Entry >::beginning | ( |  | ) |

inline

Reset to the start of the container.

Definition at line 119 of file EST_TIterator.h.

## has_more_elements()

template<class Container, class IPointer, class Entry>

bool EST_TIterator< Container, IPointer, Entry >::has_more_elements | ( |  | ) | const

inline

True if there are more elements to look at.

Definition at line 126 of file EST_TIterator.h.

## at_end()

template<class Container, class IPointer, class Entry>

bool EST_TIterator< Container, IPointer, Entry >::at_end | ( |  | ) | const

inline

True when there are no more.

Definition at line 130 of file EST_TIterator.h.

## operator int()

template<class Container, class IPointer, class Entry>

EST_TIterator< Container, IPointer, Entry >::operator int | ( |  | ) | const

inline

Viewing the iterator as an integer (for instance in a test) sees a non-zero value iff there are elements still to look at.

Definition at line 136 of file EST_TIterator.h.

## next()

template<class Container, class IPointer, class Entry>

void EST_TIterator< Container, IPointer, Entry >::next | ( |  | ) |

inline

Next moves to the next entry.

Definition at line 144 of file EST_TIterator.h.

## operator++() [1/2]

template<class Container, class IPointer, class Entry>

Iter & EST_TIterator< Container, IPointer, Entry >::operator++ | ( |  | ) |

inline

The increment operator does the same as next.

Definition at line 148 of file EST_TIterator.h.

## operator++() [2/2]

template<class Container, class IPointer, class Entry>

Iter EST_TIterator< Container, IPointer, Entry >::operator++ | ( | int | dummy | ) |

inline

Definition at line 150 of file EST_TIterator.h.

## current()

template<class Container, class IPointer, class Entry>

const Entry & EST_TIterator< Container, IPointer, Entry >::current | ( |  | ) | const

inline

Return the element currently pointed to.

Definition at line 163 of file EST_TIterator.h.

## operator*()

template<class Container, class IPointer, class Entry>

const Entry & EST_TIterator< Container, IPointer, Entry >::operator* | ( |  | ) | const

inline

The * operator returns the current element.

Definition at line 167 of file EST_TIterator.h.

## next_element()

template<class Container, class IPointer, class Entry>

const Entry & EST_TIterator< Container, IPointer, Entry >::next_element | ( |  | ) |

inline

Return the current element and move the pointer forwards.

Definition at line 177 of file EST_TIterator.h.

## n()

template<class Container, class IPointer, class Entry>

unsigned int EST_TIterator< Container, IPointer, Entry >::n | ( |  | ) | const

inline

Return the current position.

Definition at line 186 of file EST_TIterator.h.

## Friends And Related Symbol Documentation

## EST_TStructIterator< Container, IPointer, Entry >

template<class Container, class IPointer, class Entry>

friend class EST_TStructIterator< Container, IPointer, Entry >

friend

Definition at line 186 of file EST_TIterator.h.

## EST_TRwIterator< Container, IPointer, Entry >

template<class Container, class IPointer, class Entry>

friend class EST_TRwIterator< Container, IPointer, Entry >

friend

Definition at line 186 of file EST_TIterator.h.

## EST_TRwStructIterator< Container, IPointer, Entry >

template<class Container, class IPointer, class Entry>

friend class EST_TRwStructIterator< Container, IPointer, Entry >

friend

Definition at line 186 of file EST_TIterator.h.

## Member Data Documentation

## cont

template<class Container, class IPointer, class Entry>

Container* EST_TIterator< Container, IPointer, Entry >::cont

protected

The container we are looking at.

Definition at line 85 of file EST_TIterator.h.

## pos

template<class Container, class IPointer, class Entry>

unsigned int EST_TIterator< Container, IPointer, Entry >::pos

protected

Position in the structure. May or may not be useful.

Definition at line 88 of file EST_TIterator.h.

## pointer

template<class Container, class IPointer, class Entry>

IPointer EST_TIterator< Container, IPointer, Entry >::pointer

protected

Structure defined by the container class which contains the current state of the iteration.

Definition at line 93 of file EST_TIterator.h.

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

- include/EST_TIterator.h