Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

MCDictionary Class Reference

STL safe dictionary (map). More...

#include <mcllib/MCDictionary.h>

Inheritance diagram for MCDictionary:

MCBase MCDBMetaData MCDBConnectionMetaData MCDBResultSetMetaData List of all members.

Public Member Functions

bool containsKey (const MCVariantType &key) const
 Check to see if an item exists in the dictionary.
MCVariantType get (const MCVariantType &key) const
 Get the value for a key.
 MCDictionary ()
 Construct an empty dictionary.
void put (const MCVariantType &key, const MCVariantType &value)
 Add an item to the dictionary.
void remove (const MCVariantType &key)
 Remove an item from the dictionary.

Protected Member Functions

 MCDictionary (void *impl)

Detailed Description

STL safe dictionary (map).

Todo:
Dictionary enumerator


Member Function Documentation

bool containsKey const MCVariantType key  )  const
 

Check to see if an item exists in the dictionary.

Parameters:
key the key to check for
Returns:
true if the key is present in the dictionary.

MCVariantType get const MCVariantType key  )  const
 

Get the value for a key.

Parameters:
key the key to obtain the value for
Returns:
the value for the key. If the key is not present in the dicitonary a null variant type is returned. See MCVariantType::isDefined()

void put const MCVariantType key,
const MCVariantType value
 

Add an item to the dictionary.

If key is already present in the dictionary, the existing value will be overwritten.

Parameters:
key the key for the item
value the value to associate with the key.

void remove const MCVariantType key  ) 
 

Remove an item from the dictionary.

If key is not present in the dictionary no action is taken.

Parameters:
key the key to remove


Generated on Wed Jan 12 19:05:49 2005 for MCLLIB by  doxygen 1.3.9.1