BKeyValuePairs Class Reference

#include <BKeyValuePairs.h>

Inheritance diagram for BKeyValuePairs:

Inheritance graph
[legend]

List of all members.


Detailed Description

A collection of key / value pairs.

Public Member Functions

void Add (const BString &key, const BPoint &val)
 Adds a key / value pair to this collection.
void Add (const BString &key, Int64 val)
 Adds a key / value pair to this collection.
void Add (const BString &key, bool val)
 Adds a key / value pair to this collection.
void Add (const BString &key, float val)
 Adds a key / value pair to this collection.
void Add (const BString &key, Int32 val)
 Adds a key / value pair to this collection.
void Add (const BString &key, double val)
 Adds a key / value pair to this collection.
void Add (const BString &key, const wchar_t val)
 Adds a key / value pair to this collection.
void Add (const BString &key, const char *val)
 Adds a key / value pair to this collection.
void Add (const BString &key, const BString *val)
 Adds a key / value pair to this collection.
void Add (const BString &key, const BString &val)
 Adds a key / value pair to this collection.
void Add (const BString &key, const BVariant &val)
 Adds a key / value pair to this collection.
 BKeyValuePairs (const BKeyValuePairs &kvPairs)
 Copy constructor.
 BKeyValuePairs ()
 Default constructor.
void Clear (void)
 Removes all pairs from this collection.
virtual size_t ComputeSize (void) const
 Computes the size of the BByteArray required to store this object.
virtual void FromByteArray (const BByteArray &bytes, size_t &startPos)
 Initializes an instance of this object from a BByteArray.
bool GetBoolean (const BString &key, bool defVal=false) const
 Gets the requested value from this collection.
BoolVector GetBooleans (const BString &key) const
 Gets all values that correspond to the specified key.
size_t GetCount (void) const
 Gets the number of pairs in this collection.
double GetDouble (const BString &key, double defVal=0.0) const
 Gets the requested value from this collection.
DoubleVector GetDoubles (const BString &key) const
 Gets all values that correspond to the specified key.
float GetFloat (const BString &key, float defVal=0.0) const
 Gets the requested value from this collection.
FloatVector GetFloats (const BString &key) const
 Gets all values that correspond to the specified key.
Int32 GetInteger (const BString &key, Int32 defVal=0) const
 Gets the requested value from this collection.
Int64 GetInteger64 (const BString &key, Int64 defVal=0) const
 Gets the requested value from this collection.
Int64Vector GetInteger64s (const BString &key) const
 Gets all values that correspond to the specified key.
Int32Vector GetIntegers (const BString &key) const
 Gets all values that correspond to the specified key.
BPoint GetPoint (const BString &key) const
 Gets the requested value from this collection.
void GetPropertyNames (BStringVector &names) const
 Gets a list of all key names in the collection.
BString GetString (const BString &key) const
 Gets the requested value from this collection.
BStringVector GetStrings (const BString &key) const
 Gets all values that correspond to the specified key.
bool GetValue (const BString &key, BPoint &val) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, Int64 &val, Int64 defVal=0) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, bool &val, bool defVal) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, float &val, float defVal=0.0) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, Int32 &val, Int32 defVal=0) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, double &val, double defVal=0.0) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, BString &val) const
 Gets the requested value from this collection.
bool GetValue (const BString &key, BVariant &val) const
 Gets the requested value from this collection.
bool GetValues (const BString &key, Int64Vector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, BoolVector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, FloatVector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, Int32Vector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, DoubleVector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, BStringVector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValues (const BString &key, BVariantVector &vals) const
 Gets all values that correspond to the specified key from this collection.
bool GetValueType (const BString &key, EVariantType &type) const
 Gets the data type associated with the specified key.
EVariantType GetValueType (const BString &key) const
 Returns the data type associated with the specified key.
BVariant GetVariant (const BString &key) const
 Gets the requested value from this collection.
BVariantVector GetVariants (const BString &key) const
 Gets all values that correspond to the specified key.
bool HasProperty (const BString &key) const
 Returns an indication of whether or not the requested key name exists in this collection.
BKeyValuePairsoperator= (const BKeyValuePairs &rhs)
 Assignment operator.
void Remove (const BString &key)
 Removes all pairs with the specified key from this collection.
void SetValue (const BString &key, const BPoint &val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, Int64 val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, bool val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, float val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, Int32 val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, double val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, const wchar_t *val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, const char *val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, const BString *val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, const BString &val)
 Updates a key / value pair in this collection.
void SetValue (const BString &key, const BVariant &val)
 Updates a key / value pair in this collection.
virtual BByteArray ToByteArray (void) const
 Stores this object in a BByteArray.
virtual ~BKeyValuePairs ()
 Destructor.

Protected Attributes

BStringToAttributeMap m_keyValPairs
 The collection of key / value pairs.

Constructor & Destructor Documentation

BKeyValuePairs (  )  [inline]

Default constructor.

This constructor creates an empty collection.

BKeyValuePairs ( const BKeyValuePairs kvPairs  ) 

Copy constructor.

Parameters:
kvPairs The BKeyValuePairs object to copy.

virtual ~BKeyValuePairs (  )  [inline, virtual]

Destructor.


Member Function Documentation

void Add ( const BString key,
const BPoint val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
Int64  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
bool  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
float  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
Int32  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
double  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
const wchar_t  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
const char *  val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
const BString val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
const BString val 
) [inline]

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Add ( const BString key,
const BVariant val 
)

Adds a key / value pair to this collection.

If there already exists a pair with the specified key, the existing pair will be unchanged and a new pair will be added.

Parameters:
key The new key.
val The new value.

void Clear ( void   )  [inline]

Removes all pairs from this collection.

virtual size_t ComputeSize ( void   )  const [virtual]

Computes the size of the BByteArray required to store this object.

Returns:
The size of the BByteArray.

Implements BByteStreamable.

virtual void FromByteArray ( const BByteArray bytes,
size_t &  startPos 
) [virtual]

Initializes an instance of this object from a BByteArray.

Parameters:
bytes The BByteArray containing the byte representation of the object.
startPos The position in the BByteArray where the byte representation begins. This value will be updated to point to the byte past the end of this object in the byte array.

Implements BByteStreamable.

bool GetBoolean ( const BString key,
bool  defVal = false 
) const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
defVal The default value for the returned boolean.
Returns:
The value that corresponds to the specified key, as a boolean.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a boolean.

BoolVector GetBooleans ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a boolean.

size_t GetCount ( void   )  const [inline]

Gets the number of pairs in this collection.

Returns:
The number of pairs in this collection.

double GetDouble ( const BString key,
double  defVal = 0.0 
) const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
defVal The default value for the returned double.
Returns:
The value that corresponds to the specified key, as a double.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a double.

DoubleVector GetDoubles ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a double.

float GetFloat ( const BString key,
float  defVal = 0.0 
) const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
defVal The default value for the returned float.
Returns:
The value that corresponds to the specified key, as a float.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a float.

FloatVector GetFloats ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a float.

Int32 GetInteger ( const BString key,
Int32  defVal = 0 
) const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
defVal The default value for the returned integer.
Returns:
The value that corresponds to the specified key, as an integer.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not an integer.

Int64 GetInteger64 ( const BString key,
Int64  defVal = 0 
) const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
defVal The default value for the returned Int64.
Returns:
The value that corresponds to the specified key, as an Int64.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not an Int64.

Int64Vector GetInteger64s ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not an Int64.

Int32Vector GetIntegers ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not an integer.

BPoint GetPoint ( const BString key  )  const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
Returns:
The value that corresponds to the specified key, as a BPoint.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a BPoint.

void GetPropertyNames ( BStringVector names  )  const

Gets a list of all key names in the collection.

Parameters:
names The collection in which the key names will be placed.

BString GetString ( const BString key  )  const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
Returns:
The value that corresponds to the specified key, as a BString.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a BString.

BStringVector GetStrings ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a BString.

bool GetValue ( const BString key,
BPoint val 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a BPoint.

bool GetValue ( const BString key,
Int64 &  val,
Int64  defVal = 0 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
defVal The default value for the returned Int64. If there are not any pairs with the specified key, then val will be set to this value.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not an Int64.

bool GetValue ( const BString key,
bool &  val,
bool  defVal 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
defVal The default value for the returned bool. If there are not any pairs with the specified key, then val will be set to this value.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a bool.

bool GetValue ( const BString key,
float &  val,
float  defVal = 0.0 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
defVal The default value for the returned float. If there are not any pairs with the specified key, then val will be set to this value.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a float.

bool GetValue ( const BString key,
Int32 val,
Int32  defVal = 0 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
defVal The default value for the returned integer. If there are not any pairs with the specified key, then val will be set to this value.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not an integer.

bool GetValue ( const BString key,
double &  val,
double  defVal = 0.0 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
defVal The default value for the returned double. If there are not any pairs with the specified key, then val will be set to this value.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a double.

bool GetValue ( const BString key,
BString val 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if the value that corresponds to the specified key is not a BString.

bool GetValue ( const BString key,
BVariant val 
) const

Gets the requested value from this collection.

Parameters:
key The key that corresponds to the desired value.
val After the method returns, this parameter will hold the value associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.

bool GetValues ( const BString key,
Int64Vector &  vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not an Int64.

bool GetValues ( const BString key,
BoolVector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a bool.

bool GetValues ( const BString key,
FloatVector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a float.

bool GetValues ( const BString key,
Int32Vector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not an integer.

bool GetValues ( const BString key,
DoubleVector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a double.

bool GetValues ( const BString key,
BStringVector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.
Exceptions:
BAttributeDataException This exception will be thrown if a value that corresponds to the specified key is not a BString.

bool GetValues ( const BString key,
BVariantVector vals 
) const

Gets all values that correspond to the specified key from this collection.

Parameters:
key The key that corresponds to the desired values.
vals After this method returns, this parameter will hold all values associated with the specified key.
Returns:
True if the key was found in this collection and false otherwise.

bool GetValueType ( const BString key,
EVariantType type 
) const

Gets the data type associated with the specified key.

Parameters:
key The key name.
type After this method returns, this will hold he data type that corresponds to the specified key.
Returns:
True if the key exists in the collection and false otherwise.

EVariantType GetValueType ( const BString key  )  const

Returns the data type associated with the specified key.

This method will throw an exception if the specified key does not exist.

Parameters:
key The key name.
Returns:
The data type that corresponds to the specified key.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist an element with the specified key.

BVariant GetVariant ( const BString key  )  const

Gets the requested value from this collection.

If there is more than one pair with the specified key, the value of the first pair will be returned.

Parameters:
key The key that corresponds to the desired value.
Returns:
The value that corresponds to the specified key.
Exceptions:
BKeyNotFoundException This exception will be thrown if there does not exist a pair with the specified key.

BVariantVector GetVariants ( const BString key  )  const

Gets all values that correspond to the specified key.

Parameters:
key The key that corresponds to the desired values.
Returns:
A collection containing all values that correspond to the specified key. If there are not any pairs with the specified key, this collection will be empty.

bool HasProperty ( const BString key  )  const

Returns an indication of whether or not the requested key name exists in this collection.

Parameters:
key The key to test for containment.
Returns:
True if the key exists and false otherwise.

BKeyValuePairs& operator= ( const BKeyValuePairs rhs  ) 

Assignment operator.

Parameters:
rhs The BKeyValuePairs object whose value will be copied into this one.
Returns:
A reference to this BKeyValuePairs.

void Remove ( const BString key  )  [inline]

Removes all pairs with the specified key from this collection.

Parameters:
key The key that identifies the pair(s) to be removed.

void SetValue ( const BString key,
const BPoint val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
Int64  val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
bool  val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
float  val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
Int32  val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
double  val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
const wchar_t *  val 
) [inline]

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
const char *  val 
) [inline]

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
const BString val 
) [inline]

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
const BString val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

void SetValue ( const BString key,
const BVariant val 
)

Updates a key / value pair in this collection.

If a pair with the specified key does not exist, it will be added. If there are multiple pairs with the specified key, they will all be removed and replaced by this one.

Parameters:
key The new key.
val The new value

virtual BByteArray ToByteArray ( void   )  const [virtual]

Stores this object in a BByteArray.

Returns:
A BByteArray that stores the contents of this object.

Implements BByteStreamable.


Member Data Documentation

BStringToAttributeMap m_keyValPairs [protected]

The collection of key / value pairs.


The documentation for this class was generated from the following file:

GeoTranslate 5.0 From Blue Marble Geographics