Rogue Wave banner
Previous fileTop of documentContentsIndexNext file

RWSlistCollectables


RWSlistCollectables-->RWSequenceable-->RWCollection -->RWCollectable

Data Type and Member Function Indexes
(exclusive of constructors and destructors)

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

RWBoolean
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 RWBoolean
contains(const RWCollectable* target) const;
RWBoolean
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 RWBoolean
isEmpty() const;
virtual RWCollectable*
last() const;
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 documentContentsIndexNext file
©Copyright 1999, Rogue Wave Software, Inc.
Send mail to report errors or comment on the documentation.