SourcePro® C++ 13.1 |
SourcePro® C++ API Reference Guide |
Product Documentation: SourcePro C++ Documentation Home |
A hash table for key-value pairs. Items are found by requiring them to be identical. More...
#include <rw/idendict.h>
Additional Inherited Members | |
Static Public Member Functions inherited from RWCollectable | |
static RWClassID | classID (const RWStringID &name) |
static RWClassID | classIsA () |
static bool | isAtom (RWClassID id) |
static RWspace | nilStoreSize () |
Static Public Attributes inherited from RWCollection | |
static size_t | DEFAULT_CAPACITY |
Related Functions inherited from RWCollection | |
typedef void(* | RWapplyCollectable )(RWCollectable *, void *) |
typedef bool(* | RWtestCollectable )(const RWCollectable *, const void *) |
typedef bool(* | RWtestCollectablePair )(const RWCollectable *, const RWCollectable *, const void *) |
The class RWIdentityDictionary is implemented as a hash table, for the storage and retrieval of key-value pairs. Class RWIdentityDictionary is similar to class RWHashDictionary except that items are found by requiring that they be identical (i.e., have the same address) as the key, rather than being equal (i.e., test true
for isEqual()).
Both keys and values must inherit from the abstract base class RWCollectable.
The iterator for this class is RWHashDictionaryIterator.
None
RWIdentityDictionary::RWIdentityDictionary | ( | size_t | n = RWCollection::DEFAULT_CAPACITY | ) |
Constructs an empty identity dictionary with n hashing buckets.
|
inline |
Copy constructor. Makes a shallow copy of h.
|
inline |
Move constructor. The constructed RWIdentityDictionary takes ownership of the data owned by h.
|
virtual |
Returns __RWIDENTITYDICTIONARY
.
Reimplemented from RWHashDictionary.
|
virtual |
Returns true
if the collectable object "matches" the object at address t. The default definition is:
i.e., both objects have the same address (a test for identity). The definition may be redefined in any consistent way.
Reimplemented from RWHashDictionary.
|
virtual |
Allocates a new object off the heap of the same type as self and returns a pointer to it. You are responsible for deleting the object when done with it.
Reimplemented from RWHashDictionary.
|
inline |
Returns true
if self is a subset of h, that is, every element of self has a counterpart in h which isEqual(). This operator is not explicitly present unless you are compiling with an implementation of the C++ Standard Library. It is normally inherited from RWHashDictionary.
|
inline |
Assignment operator. Makes a shallow copy of the collection h.
|
inline |
Move assignment. Self takes ownership of the data owned by h.
Copyright © 2015 Rogue Wave Software, Inc. All Rights Reserved. |