SourcePro® API Reference Guide

 
List of all members | Public Member Functions
RWSetConstIterator Class Reference

Const iterator for class RWSet, to allow sequential access to all elements of RWSet. More...

#include <rw/rwset.h>

Inheritance diagram for RWSetConstIterator:
RWHashTableConstIterator RWConstIterator RWHashDictionaryConstIterator

Public Member Functions

 RWSetConstIterator (const RWSet &h)
 
 RWSetConstIterator (const RWSetIterator &it)
 
void reset ()
 
- Public Member Functions inherited from RWHashTableConstIterator
 RWHashTableConstIterator (const RWHashTable &h)
 
 RWHashTableConstIterator (const RWHashTableConstIterator &)
 
 RWHashTableConstIterator (const RWHashTableIterator &it)
 
virtual const RWCollectablefindNext (const RWCollectable *target)
 
virtual const RWCollectablekey () const
 
virtual const RWCollectableoperator() ()
 

Detailed Description

One of two iterators for class RWSet. This const iterator allows sequential access to all the elements of RWSet and prohibits any changes to the contents of the data structure.

Note
An RWSet is unordered; elements are not accessed in any particular order.

The "current item" is undefined immediately after construction. You must define it by using operator()() or some other (valid) operation.

Once the iterator has advanced beyond the end of the collection, it is no longer valid.

Synopsis
#include <rw/rwset.h>
Persistence
None

Constructor & Destructor Documentation

RWSetConstIterator::RWSetConstIterator ( const RWSet h)
inline

Constructs a const iterator for an RWSet. After construction, the position of the iterator is undefined.

RWSetConstIterator::RWSetConstIterator ( const RWSetIterator it)
inline

Constructs a const iterator from an iterator. After construction, the position of the const iterator is undefined.

Member Function Documentation

void RWSetConstIterator::reset ( )
inlinevirtual

Resets the iterator to the state it had immediately after construction.

Reimplemented from RWHashTableConstIterator.

Copyright © 2023 Rogue Wave Software, Inc., a Perforce company. All Rights Reserved.