cQueue::Iterator Class Reference

Walks along a cQueue. More...

#include <cqueue.h>

List of all members.

Public Member Functions

 Iterator (const cQueue &q, bool reverse=false)
void init (const cQueue &q, bool reverse=false)
cObjectoperator() ()
bool end () const
cObjectoperator++ (int)
cObjectoperator-- (int)

Detailed Description

Walks along a cQueue.


Constructor & Destructor Documentation

cQueue::Iterator::Iterator ( const cQueue q,
bool  reverse = false 
) [inline]

Constructor.

Iterator will walk on the queue passed as argument. The iterator can be initialized for forward (front-to-back, using ++) or reverse (back-to-front, using --) iteration.


Member Function Documentation

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

Returns the current object, then moves the iterator to the next item (towards the back of the queue).

If the iterator has previously reached either end of the queue, nothing happens, and one has to call init() to restart iterating.

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

Returns the current object, then moves the iterator to the previous item (towards the front of the queue).

If the iterator has previously reached either end of the queue, nothing happens, and one has to call init() to restart iterating.


The documentation for this class was generated from the following file:
Generated on Tue Dec 2 11:16:30 2014 for OMNeT++ Simulation Library by  doxygen 1.6.3