Tools.h++ Class Reference

Table Of Contents
Click on the banner to return to the Class Reference home page.
©Copyright 1996 Rogue Wave Software
RWSlistCollectablesStack
RWSlistCollectablesStack RWSlistCollectables RWSequenceable ...
... RWCollection RWCollectable
Synopsis
Description
Persistence
Public Constructors
Assignment Operator
Public Member Functions
Synopsis
// Smalltalk typedef:
typedef RWSlistCollectablesStack Stack;
#include <rw/stackcol.h>
RWSlistCollectablesStack a;
Description
Class RWSlistCollectablesStack represents a restricted interface to class RWSlistCollectables to implement a last in first out
(LIFO) stack. A Stack is a sequential list for which all insertions and deletions are made at one end (the beginning of the list).
Hence, the ordering is determined externally by the ordering of the insertions. Duplicates are allowed.
An object stored by RWSlistCollectablesStack 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 stack.
This class corresponds to the Smalltalk class Stack.
Persistence
Polymorphic
Public Constructors
RWSlistCollectablesStack();
Construct an empty stack.
RWSlistCollectablesStack(RWCollectable* a);
Construct a stack with one entry a.
RWSlistCollectablesStack(const RWSlistCollectablesStack& s);
Copy constructor. A shallow copy of the stack s is made.