MSenContext Class Reference

class MSenContext

This is the abstract super class for all WSF context classes, providing convenience methods for basic, excessively used data types, and some foundation methods for general context properties, like context type and direction.

Member Functions Documentation

Add(const TDesC8 &, const TDesC8 &)

TInt Add ( const TDesC8 & aKey,
const TDesC8 & aValue
) [pure virtual]

Adds new const TDesC8 & type value into context, identified by given key.

Parameters

const TDesC8 & aKey identifies new value
const TDesC8 & aValue is the value being added.

Add(const TDesC8 &, TInt)

TInt Add ( const TDesC8 & aKey,
TInt aValue
) [pure virtual]

Adds new TInt type value into context, identified by given key.

Parameters

const TDesC8 & aKey identifies new value
TInt aValue is the value being added.

Add(const TDesC8 &, CSenElement *)

TInt Add ( const TDesC8 & aKey,
CSenElement * aValue
) [pure virtual]

Adds new CSenElement* type value into context, identified by given key.

Parameters

const TDesC8 & aKey identifies new value
CSenElement * aValue is the value being added. Ownership is transferred to this context.

Add(const TDesC8 &, TAny *)

TInt Add ( const TDesC8 & aKey,
TAny * aValue
) [pure virtual]

Adds new TAny* type value into context, identified by given key.

Parameters

const TDesC8 & aKey identifies new value
TAny * aValue is the value being added. Ownership is NOT transferred to this context.

Count()

TInt Count ( ) const [pure virtual]

Methods tells the count of context items (key-value pairs).

Direction()

SenContext::TContextDirection Direction ( ) const [pure virtual]

Indicates the direction this context is serving.

GetAnyL(const TDesC8 &)

TAny * GetAnyL ( const TDesC8 & aKey ) [pure virtual]

Method returns TAny* type value.

Parameters

const TDesC8 & aKey identifying the requested value

GetDesC8L(const TDesC8 &)

const TDesC8 * GetDesC8L ( const TDesC8 & aKey ) [pure virtual]

Method returns TDesC8* type value.

Parameters

const TDesC8 & aKey identifies descriptor object

GetIntL(const TDesC8 &)

const TInt * GetIntL ( const TDesC8 & aKey ) [pure virtual]

Method returns TInt* type value.

Parameters

const TDesC8 & aKey identifies integer object

GetParser()

const CSenXmlReader * GetParser ( ) [pure virtual]

Method returns XML parser (CSenXmlReader*)

GetSenElementL(const TDesC8 &)

const CSenElement * GetSenElementL ( const TDesC8 & aKey ) [pure virtual]

Method returns CSenElement* type value.

Parameters

const TDesC8 & aKey identifies the XML element object

KeyAtL(TInt)

TPtrC8 KeyAtL ( TInt aIndex ) [pure virtual]

Resolves key at certain index, if it is not out of bounds of the current context.

Parameters

TInt aIndex

Remove(const TDesC8 &)

TInt Remove ( const TDesC8 & aKey ) [pure virtual]

Removes value from the context, possibly destroying the value, too - if it is owned by this context.

Parameters

const TDesC8 & aKey used to identify value which needs to be removed

Reset()

void Reset ( ) [pure virtual]

Method clears (possibly destroys) the current contents of this context, making it possible to re-use this instance.

SetDirection(SenContext::TContextDirection)

TInt SetDirection ( SenContext::TContextDirection aDirection ) [pure virtual]

Sets the direction (inbound or outbound for this context).

Parameters

SenContext::TContextDirection aDirection

Type()

SenContext::TContextType Type ( ) const [pure virtual]

Method is used to resolve concrete type (class) for this context.

Update(const TDesC8 &, const TDesC8 &)

TInt Update ( const TDesC8 & aKey,
const TDesC8 & aValue
) [pure virtual]

Updates new const TDesC8 & type value into context, identified by given key. If some value for the same key already exists, it is destroyed and replaced by the new value. If key does not already exist, a new one will be added.

Parameters

const TDesC8 & aKey identifies new value
const TDesC8 & aValue is the updated value, which may replace any existing value, which used same key. Ownership is transferred to this context.

Update(const TDesC8 &, TInt)

TInt Update ( const TDesC8 & aKey,
TInt aValue
) [pure virtual]

Updates new TInt type value into context, identified by given key. If some value for the same key already exists, it is destroyed and replaced by the new value.

Parameters

const TDesC8 & aKey identifies new value
TInt aValue is the updated value, which may replace any existing value, which used same key.

Update(const TDesC8 &, CSenElement *)

TInt Update ( const TDesC8 & aKey,
CSenElement * aValue
) [pure virtual]

Updates new CSenElement* type value into context, identified by given key. If some value for the same key already exists, it is destroyed and replaced by the new value.

Parameters

const TDesC8 & aKey identifies new value
CSenElement * aValue is the updated value, which may replace any existing value, which used same key. Ownership is transferred to this context.

Update(const TDesC8 &, TAny *)

TInt Update ( const TDesC8 & aKey,
TAny * aValue
) [pure virtual]

Updates new TAny* type value into context, identified by given key. If some value for the same key already exists, it is replaced with the new value.

Parameters

const TDesC8 & aKey identifies new value
TAny * aValue is the updated value, which may replace any existing value, which used same key. Ownership is NOT transferred this context.