Tools.h++ Manual

104011 Tandem Computers Incorporated 21-175
21
RWSlistCollectablesQueue
RWSlistCollectablesQueue
|
RWSlistCollectables
||
RWSequenceable RWSlist
|
RWCollection
|
RWCollectable
Synopsis
// Smalltalk typedef:
typedef RWSlistCollectablesQueue Queue;
#include <rw/queuecol.h>
RWSlistCollectablesQueue a;
Description Class
RWSlistCollectablesQueue
represents a restricted interface to class
RWSlistCollectables
to implement a first in first out (FIFO) queue. A
Queue is a sequential list for which all insertions are made at one end (the
"tail"), but all removals are made at the other end (the "head"). Hence, the
ordering is determined externally by the ordering of the insertions. Duplicates
are allowed.
An object stored by
RWSlistCollectablesQueue
must inherit abstract base
class
RWCollectable
. The virtual function
isEqual()
(see class
RWCollectable
) is required to find a match between a target and an item in
the queue.
This class corresponds to the
Smalltalk
class
Queue
.
Public constructors
RWSlistCollectablesQueue();
Construct an empty queue.
RWSlistCollectablesQueue(RWCollectable* a);
Construct an queue with single item
a
.