By using typedefs to define the collection classes you use, you can easily replace the default implementation with another implementation. Suppose that you have a key set class called MyType that has been defined with the default implementation IKeySet. The definition of this class would look like this:
typedef IKeySet<Element, Key> MyType;
If you want to replace the default implementation, which uses an AVL tree, with a hash table implementation, you can replace the above implementation with the following definition:
typedef IHashKeySet<Element, Key> MyType;
If you replace a collection's default implementation with one of its implementation variants, you must determine what element functions and key-type functions need to be provided for the variant. You must then provide those functions. The list of required functions is not always the same for a collection's default implementation as for particular implementation variants.
Introduction
to the Collection Classes
Collection
Class Hierarchy
Overall
Implementation Structure
Collection
Class Polymorphism
Flat
Collections
Trees
AVL Tree
B* Tree
Diluted
Table
Hash
Table
List
Table
Class Template Naming
Conventions
Possible Implementation Paths
Choosing One of the
Provided Implementation Variants
Taking Advantage of
the Abstract Class Hierarchy