cQueue::Iterator Class Reference

#include <cqueue.h>

List of all members.


Detailed Description

Walks along a cQueue.


Public Member Functions

 Iterator (const cQueue &q, bool athead=true)
void init (const cQueue &q, bool athead=true)
cObjectoperator[] (int)
cObjectoperator() ()
bool end () const
cObjectoperator++ (int)
cObjectoperator-- (int)


Constructor & Destructor Documentation

cQueue::Iterator::Iterator const cQueue q,
bool  athead = true
[inline]
 

Constructor.

Iterator will walk on the queue passed as argument. The current object will be the first (if athead==true) or the last (athead==false) object in the queue.


Member Function Documentation

bool cQueue::Iterator::end  )  const [inline]
 

Returns true if the iterator has reached either end of the queue.

void cQueue::Iterator::init const cQueue q,
bool  athead = true
[inline]
 

Reinitializes the iterator object.

cObject* cQueue::Iterator::operator()  )  [inline]
 

Returns the current object.

cObject* cQueue::Iterator::operator++ int   )  [inline]
 

Returns the current object, then moves the iterator to the next item.

If the iterator has reached either end of the queue, nothing happens; you have to call init() again to restart iterating.

cObject* cQueue::Iterator::operator-- int   )  [inline]
 

Returns the current object, then moves the iterator to the previous item.

If the iterator has reached either end of the queue, nothing happens; you have to call init() again to restart iterating.

cObject& cQueue::Iterator::operator[] int   )  [inline]
 

DEPRECATED.

Use operator () instead.


The documentation for this class was generated from the following file:
Generated on Sat Oct 21 17:47:57 2006 for OMNeT++/OMNEST Simulation Library by  doxygen 1.4.6