Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

vtkObjectHashMap Class Reference

#include <vtkObjectHashMap.h>

Inheritance diagram for vtkObjectHashMap:

Inheritance graph
[legend]
Collaboration diagram for vtkObjectHashMap:

Collaboration graph
[legend]
List of all members.

Detailed Description

A hash map object for objects.

Calls Register when objects are inserted into the map and UnRegister when the object is removed.

Author:
Sean McInerney
Version:
Revision
1.9
Date:
Date
2004/06/03 18:58:28
See also:
vtkObjectBaseHashMap vtkObject

Definition at line 36 of file vtkObjectHashMap.h.

Public Member Functions

 vtkTypeRevisionMacro (vtkObjectHashMap, vtkObjectBaseHashMap)
virtual int Swap (vtkObjectHashMap *container)
 Swaps elements of this object with those of the specified container.

vtkObjectFind (const char *key) const
 Find the entry in the table with the given key string.

virtual int Insert (const char *key, vtkObject *object)
 Insert an object into the table paired with a key string.

virtual const char * FindKey (const vtkObject *object)
 Find the first key in the map associated with an object pointer.

vtkObjectHashMapIteratorCreateIterator (void)
 Create an iterator.

Data Access Methods
vtkObjectFront (void) const
 Get a read/write pointer to the first object in the container.

virtual int Front (const char *&key, vtkObject *&object) const
 Gets the first key - object association in the map.

vtkObjectBack (void) const
 Get a read/write pointer to the last object in the container.

virtual int Back (const char *&key, vtkObject *&object) const
 Gets the last key - object association in the map.


Static Public Member Functions

vtkObjectHashMapNew (void)

Protected Member Functions

 vtkObjectHashMap (void)
 ~vtkObjectHashMap ()


Constructor & Destructor Documentation

vtkObjectHashMap::vtkObjectHashMap void   )  [inline, protected]
 

Definition at line 124 of file vtkObjectHashMap.h.

vtkObjectHashMap::~vtkObjectHashMap  )  [inline, protected]
 

Definition at line 125 of file vtkObjectHashMap.h.


Member Function Documentation

int vtkObjectHashMap::Back const char *&  key,
vtkObject *&  object
const [inline, virtual]
 

Gets the last key - object association in the map.

Returns:
false if the map is empty or this iterator has not been initialized to traverse any map, otherwise true.

Definition at line 167 of file vtkObjectHashMap.h.

vtkObject* vtkObjectHashMap::Back void   )  const [inline, virtual]
 

Get a read/write pointer to the last object in the container.

Returns:
null if the container is empty, otherwise returns a pointer to an object.

Reimplemented from vtkObjectBaseHashMap.

Reimplemented in vtkExtensionsObjectHashMap, vtkPaletteElementHashMap, and vtkPaletteHashMap.

Definition at line 108 of file vtkObjectHashMap.h.

vtkObjectHashMapIterator* vtkObjectHashMap::CreateIterator void   )  [virtual]
 

Create an iterator.

Reimplemented from vtkObjectBaseHashMap.

Reimplemented in vtkExtensionsObjectHashMap, vtkPaletteElementHashMap, and vtkPaletteHashMap.

vtkObject* vtkObjectHashMap::Find const char *  key  )  const [inline, virtual]
 

Find the entry in the table with the given key string.

Parameters:
key A unique string serving as the map key.
Returns:
The object associated with the specified key if found or NULL if the key is removed, empty, or non-existant.
Note:
Covariant return type.

Reimplemented from vtkObjectBaseHashMap.

Reimplemented in vtkExtensionsObjectHashMap, vtkPaletteElementHashMap, and vtkPaletteHashMap.

Definition at line 59 of file vtkObjectHashMap.h.

virtual const char* vtkObjectHashMap::FindKey const vtkObject object  )  [inline, virtual]
 

Find the first key in the map associated with an object pointer.

Returns:
true on success, false otherwise.

Definition at line 82 of file vtkObjectHashMap.h.

int vtkObjectHashMap::Front const char *&  key,
vtkObject *&  object
const [inline, virtual]
 

Gets the first key - object association in the map.

Returns:
false if the map is empty or this iterator has not been initialized to traverse any map, otherwise true.

Definition at line 157 of file vtkObjectHashMap.h.

vtkObject* vtkObjectHashMap::Front void   )  const [inline, virtual]
 

Get a read/write pointer to the first object in the container.

Returns:
null if the container is empty, otherwise returns a pointer to an object.

Reimplemented from vtkObjectBaseHashMap.

Reimplemented in vtkExtensionsObjectHashMap, vtkPaletteElementHashMap, and vtkPaletteHashMap.

Definition at line 92 of file vtkObjectHashMap.h.

virtual int vtkObjectHashMap::Insert const char *  key,
vtkObject object
[inline, virtual]
 

Insert an object into the table paired with a key string.

Parameters:
key A unique string serving as the map key.
object An object to be associated with the key.
Exceptions:
bad_alloc Internal use of operator new may throw.
overflow_error Thrown for requests to grow the table beyond its maximum capacity (~ 1<<31).
Returns:
true for successful additions to the table or false when attempting to insert empty or duplicate strings.

Definition at line 74 of file vtkObjectHashMap.h.

vtkObjectHashMap* vtkObjectHashMap::New void   )  [static]
 

Reimplemented from vtkObjectBaseHashMap.

Reimplemented in vtkExtensionsObjectHashMap, vtkPaletteElementHashMap, and vtkPaletteHashMap.

virtual int vtkObjectHashMap::Swap vtkObjectHashMap container  )  [inline, virtual]
 

Swaps elements of this object with those of the specified container.

Returns:
true on success, otherwise false.

Definition at line 47 of file vtkObjectHashMap.h.

References Swap().

vtkObjectHashMap::vtkTypeRevisionMacro vtkObjectHashMap  ,
vtkObjectBaseHashMap 
 


The documentation for this class was generated from the following file:
Generated on Tue Aug 10 03:42:56 2004 for vtkExtensions by doxygen 1.3.7