Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Essential Tools Module Reference Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

RWSlistCollectables

Module:  Essential Tools Module   Group:  RWCollectable Classes


RWSlistCollectablesRWSequenceableRWCollection... ...RWCollectable

Local Index

Members

Synopsis

// Smalltalk typedef:
typedef RWSlistCollectables LinkedList ;
#include <rw/slistcol.h>
RWSlistCollectables a;

Description

Class RWSlistCollectables represents a group of ordered elements, without keyed access. Duplicates are allowed. The ordering of elements is determined externally, by the order of insertion and removal. An object stored by RWSlistCollectables 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 collection

Class RWSlistCollectables is implemented as a singly-linked list, which allows for efficient insertion and removal, but efficient movement in only one direction. This class corresponds to the Smalltalk class LinkedList.

Persistence

Polymorphic

Public Constructors

RWSlistCollectables();
RWSlistCollectables(RWCollectable* a);

Public Member Operators

bool
operator==(const RWSlistCollectables& s) const;

Public Member Functions

virtual RWCollectable*
append(RWCollectable*);
virtual void
apply(RWapplyCollectable ap, void*);
virtual RWCollectable*&
at(size_t i);
virtual const RWCollectable*
at(size_t i) const;
virtual RWspace
binaryStoreSize() const;
virtual void
clear();
virtual void
clearAndDestroy();
virtual int
compareTo(const RWCollectable* a) const;
virtual bool
contains(const RWCollectable* target) const;
bool
containsReference(const RWCollectable* e) const;
virtual size_t
entries() const;
virtual RWCollectable*
find(const RWCollectable* target) const;
RWCollectable*
findReference(const RWCollectable* e) const;
virtual RWCollectable*
first() const;
RWCollectable*
get();
virtual unsigned
hash() const;
virtual size_t
index(const RWCollectable* c) const;
virtual RWCollectable*
insert(RWCollectable* c);
void
insertAt(size_t indx, RWCollectable* e);
virtual RWClassID
isA() const;
virtual bool
isEmpty() const;
virtual RWCollectable*
last() const;
virtual RWIterator*
newIterator();
virtual RWConstIterator*
newConstIterator();
virtual size_t
occurrencesOf(const RWCollectable* target) const;
size_t
occurrencesOfReference(const RWCollectable* e) const;
virtual RWCollectable*
prepend(RWCollectable*);
virtual RWCollectable*
remove(const RWCollectable* target);
virtual void
removeAndDestroy(const RWCollectable* target);
RWCollectable*
removeReference(const RWCollectable* e);
virtual void
restoreGuts(RWvistream&);
virtual void
restoreGuts(RWFile&);
virtual void
saveGuts(RWvostream&) const;
virtual void
saveGuts(RWFile&) const;
RWStringID
stringID();


Previous fileTop of DocumentContentsIndex pageNext file

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, 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.