Tools.h++ Class Reference

Table Of Contents
Public Constructors
RWHashDictionary(size_t n = RWDEFAULT_CAPACITY);
Construct an empty hashed dictionary using n hashing buckets.
RWHashDictionary(const RWHashDictionary& hd);
Copy constructor. A shallow copy of the collection hd is made.
Public Member Operators
void
operator=(const RWHashDictionary& hd);
Assignment operator. A shallow copy of the collection hd is made.
RWBoolean
operator<=(const RWHashDictionary& hd) const;
Returns TRUE if for every key-value pair in self, there is a corresponding key in hd that
isEqual. Their corresponding values must also be equal. Note: If you inherit from
RWHashDictionary in the presence of the Standard C++ Library, we recommend that
you override this operator and explicitly forward the call. Overload resolution in C++
will choose the Standard Library provided global operators over inherited class members.
These global definitions are not appropriate for set-like partial orderings.
RWBoolean
operator==(const RWHashDictionary& hd) const;
Returns TRUE if self and hd have the same number of entries and if for every key-value
pair in self, there is a corresponding key in hd that isEqual. Their corresponding values
must also be equal.
Public Member Functions
void
applyToKeyAndValue(RWapplyKeyAndValue ap, void* x);
Applies the user-supplied function pointed to by ap to each key-value pair of the
collection. Items are not visited in any particular order. An untyped argument may be
passed to the ap function through x.
RWBinaryTree
asBinaryTree();
RWBag
asBag() const;
RWSet
asOrderedCollection() const;
asSet() const;