CMsvSendErrorActions Class Reference

class CMsvSendErrorActions : public CBase

This class determines what action to take if an error occurs while the Server MTM is sending a message (or messages).

It encapsulates an array of TMsvSendErrorAction objects, which it uses to determine the action to take for a particular error. If the error is not found in the array, then CMsvSendErrorActions uses its default TMsvSendErrorAction object.

Inherits from

Constructor & Destructor Documentation

CMsvSendErrorActions()

CMsvSendErrorActions ( ) [private]

~CMsvSendErrorActions()

IMPORT_C ~CMsvSendErrorActions ( )

Destructor.

Member Functions Documentation

AddSendErrorActionL(const TMsvSendErrorAction &)

IMPORT_C void AddSendErrorActionL ( const TMsvSendErrorAction & aErrorAction )

Adds a TMsvSendErrorAction object.

If a TMsvSendErrorAction already exists in the collection for the same error, then it is replaced by aAction.

leave
Any error code but KErrNone and KErrNotFound We tried to delete the error action if it already exists and RemoveSendErrorAction() returned an error.
leave
KErrAlreadyExists A duplicate was found when inserting the error action in the array.

Parameters

const TMsvSendErrorAction & aErrorAction Error action to add.

ConstructL()

void ConstructL ( ) [private]

Default()

IMPORT_C const TMsvSendErrorAction & Default ( ) const

Gets the default error-action.

The default is used if a specified error-action is not found for the error.

Errors()

IMPORT_C const CArrayFixFlat < TMsvSendErrorAction > & Errors ( ) const

Gets the object's array of error-actions.

Find(const TInt, TInt &)

TInt Find ( const TInt aError,
TInt & aIndex
) const [private]

Parameters

const TInt aError
TInt & aIndex

GetSendErrorAction(const TInt, TMsvSendErrorAction &)

IMPORT_C TInt GetSendErrorAction ( const TInt aError,
TMsvSendErrorAction & aErrorAction
) const

Gets an error action for a specified error.

Parameters

const TInt aError Error to find.
TMsvSendErrorAction & aErrorAction On return, the corresponding TMsvSendErrorAction.

NewL()

IMPORT_C CMsvSendErrorActions * NewL ( ) [static]

Allocates and creates a new CMsvSendErrorActions object.

NewLC()

IMPORT_C CMsvSendErrorActions * NewLC ( ) [static]

Allocates and creates a new CMsvSendErrorActions object.

RemoveSendErrorAction(const TInt)

IMPORT_C TInt RemoveSendErrorAction ( const TInt aError )

Removes an error action.

Parameters

const TInt aError Error to remove.

Reset()

IMPORT_C void Reset ( )

RestoreErrorActionL(TResourceReader &, TInt, const TBool)

void RestoreErrorActionL ( TResourceReader & aReader,
TInt aActionCount,
const TBool aDefault
) [private]

Parameters

TResourceReader & aReader
TInt aActionCount
const TBool aDefault

RestoreFromResourceL(TResourceReader &)

IMPORT_C void RestoreFromResourceL ( TResourceReader & aReader )

Restores the object from a resource.

The resource must be of type SEND_ERROR_ACTIONS.

Parameters

TResourceReader & aReader Resource reader at appropriate resource.

SetDefault(const TMsvSendErrorAction &)

IMPORT_C void SetDefault ( const TMsvSendErrorAction & aAction )

Sets the default error-action.

Parameters

const TMsvSendErrorAction & aAction Default error-action.

SetErrorsL(const CArrayFixFlat< TMsvSendErrorAction > &)

IMPORT_C void SetErrorsL ( const CArrayFixFlat < TMsvSendErrorAction > & aErrors )

Sets the object to an array of error-actions.

Parameters

const CArrayFixFlat < TMsvSendErrorAction > & aErrors Array to use.

Member Data Documentation

TMsvSendErrorAction iDefault

TMsvSendErrorAction iDefault [private]

CArrayFixFlat< TMsvSendErrorAction > * iErrors

CArrayFixFlat < TMsvSendErrorAction > * iErrors [private]