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

vtkPaletteMap Class Reference

#include <vtkPaletteMap.h>

Inheritance diagram for vtkPaletteMap:

Inheritance graph
[legend]
Collaboration diagram for vtkPaletteMap:

Collaboration graph
[legend]
List of all members.

Detailed Description

A map object for palettes.

Calls Register when palettes are inserted into the map and UnRegister when the palette is removed.

Author:
Sean McInerney
Version:
Revision
1.2
Date:
Date
2004/06/12 20:01:23
See also:
vtkPaletteElementMap vtkPalette

Definition at line 36 of file vtkPaletteMap.h.

Public Member Functions

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

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

virtual int Insert (const char *key, vtkPalette *palette)
 Insert a palette into the table paired with a key string.

virtual const char * FindKey (const vtkPalette *palette)
 Find the first key in the map associated with a palette pointer.

vtkPaletteMapIterator * CreateIterator (void)
 Create an iterator.

Data Access Methods
vtkPalette * Front (void) const
 Get a read/write pointer to the first palette in the map.

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

vtkPalette * Back (void) const
 Get a read/write pointer to the last palette in the map.

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


Static Public Member Functions

vtkPaletteMap * New (void)

Protected Member Functions

 vtkPaletteMap (void)
 ~vtkPaletteMap ()


Constructor & Destructor Documentation

vtkPaletteMap::vtkPaletteMap (  void   )  [inline, protected]
 

Definition at line 124 of file vtkPaletteMap.h.

vtkPaletteMap::~vtkPaletteMap (   )  [inline, protected]
 

Definition at line 125 of file vtkPaletteMap.h.


Member Function Documentation

int vtkPaletteMap::Back (  const char *&  key,
vtkPalette *&  palette
)  const [inline, virtual]
 

Gets the last key - palette 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 vtkPaletteMap.h.

vtkPalette* vtkPaletteMap::Back (  void   )  const [inline, virtual]
 

Get a read/write pointer to the last palette in the map.

Returns:
null if the map is empty, otherwise returns a pointer to a palette.

Reimplemented from vtkPaletteElementMap.

Definition at line 108 of file vtkPaletteMap.h.

vtkPaletteMapIterator* vtkPaletteMap::CreateIterator (  void   )  [virtual]
 

Create an iterator.

Reimplemented from vtkPaletteElementMap.

vtkPalette* vtkPaletteMap::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 palette associated with the specified key if found or NULL if the key is removed, empty, or non-existant.
Note:
Covariant return type.

Reimplemented from vtkPaletteElementMap.

Definition at line 59 of file vtkPaletteMap.h.

virtual const char* vtkPaletteMap::FindKey (  const vtkPalette *  palette  )  [inline, virtual]
 

Find the first key in the map associated with a palette pointer.

Returns:
true on success, false otherwise.

Definition at line 82 of file vtkPaletteMap.h.

int vtkPaletteMap::Front (  const char *&  key,
vtkPalette *&  palette
)  const [inline, virtual]
 

Gets the first key - palette 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 vtkPaletteMap.h.

vtkPalette* vtkPaletteMap::Front (  void   )  const [inline, virtual]
 

Get a read/write pointer to the first palette in the map.

Returns:
null if the map is empty, otherwise returns a pointer to a palette.

Reimplemented from vtkPaletteElementMap.

Definition at line 92 of file vtkPaletteMap.h.

virtual int vtkPaletteMap::Insert (  const char *  key,
vtkPalette *  palette
)  [inline, virtual]
 

Insert a palette into the table paired with a key string.

Parameters:
key A unique string serving as the map key.
palette A palette 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 vtkPaletteMap.h.

vtkPaletteMap* vtkPaletteMap::New (  void   )  [static]
 

Reimplemented from vtkPaletteElementMap.

virtual int vtkPaletteMap::Swap (  vtkPaletteMap *  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 vtkPaletteMap.h.

References Swap().

vtkPaletteMap::vtkTypeRevisionMacro (  vtkPaletteMap  ,
vtkPaletteElementMap 
) 
 


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