Tools.h++ Manual
22-20 104011 Tandem Computers Incorporated
22
Public member functions
RWTIsvSlist<T>* container() const;
Returns a pointer to the collection over which this iterator is iterating.
T* findNext(RWBoolean 
(*testFun)(const T*, void*), 
void*);
Advances the iterator to the first link for which the tester function pointed to 
by 
testFun 
returns 
TRUE 
and returns it, or nil if there is no such link.
void insertAfterPoint(T* a);
Inserts the link pointed to by 
a 
into the iterator's associated collection in the 
position immediately after the iterator's current position.
T* key() const;
Returns the link at the iterator's current position. Returns nil if the iterator is 
not valid.
T* remove();
Removes and returns the current link from the iterator's associated collection. 
Returns nil if unsuccessful. Afterwards, if successful, the iterator will be 
positioned at the element immediately before the removed link. This function 
is relatively inefficient for a singly-linked list.
T* removeNext(RWBoolean 
(*testFun)(const T*, void*), 
void*);
Advances the iterator to the first link for which the tester function pointed to 
by 
testFun 
returns 
TRUE
, removes and returns it. Returns 
FALSE 
if 
unsuccessful. Afterwards, if successful, the iterator will be positioned at the 
element immediately before the removed element.
void reset();
Resets the iterator to the state it had immediately after construction.
void reset(RWTIsvSlist<TL>& c);
Resets the iterator to iterate over the collection 
c
.










