Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Essential Tools Module Reference Guide

RWGDlistIterator(type)

Module:  Essential Tools Module   Group:  Generic


Does not inherit

Local Index

Members

Synopsis

#include <rw/gdlist.h>
declare(RWGDlist, type)
RWGDlist(type) a;
RWGDlistIterator(type) I(a) ;

Description

Iterator for class RWGDlist(type), which allows sequential access to all the elements of a doubly-linked list. Elements are accessed in order, in either direction.


NOTE -- RWGDlistIterator is deprecated. Please use RWTValDlistIterator or RWTPtrDlistIterator.

As with all Rogue Wave iterators, 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 -- continuing to use it will bring undefined results.

In order to simplify the documentation below, an imaginary typedef:

has been used. See the documentation for class RWGDlist(type) for an explanation of this function.

Persistence

None

Example

See class RWGDlist(type).

Public Constructor

RWGDlistIterator(type)( RWGDlist(type)& list);

Public Member Operators

type*
operator()();
void
operator++();
void
operator--();
void
operator+=(size_t n);
void
operator-=(size_t n);

Public Member Functions

RWBoolean
atFirst() const;
RWBoolean
atLast() const;
type*
findNext(yourTester t,const type* d);
type*
findNextReference(const type* e);
type*
insertAfterPoint(type* a);
type*
key() const;
type*
remove();
type*
removeNext(yourTester t, const type* d);
type*
removeNextReference(const type* a);
void
reset();
void
toFirst();
void
toLast();


Previous fileTop of DocumentContentsIndex pageNext file

©2004 Copyright Quovadx, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Quovadx, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.