#include <mw/msvapi.h>
class CMsvCompletedOperation : public CMsvOperation, public CMsvOperation |
Public Member Functions | |
---|---|
~CMsvCompletedOperation() | |
virtual const TDesC8 & | FinalProgress() |
IMPORT_C CMsvCompletedOperation * | NewL(CMsvSession &, TUid, const TDesC8 &, TMsvId, TRequestStatus &, TInt) |
virtual const TDesC8 & | ProgressL() |
Inherited Attributes | |
---|---|
CActive::iStatus | |
CMsvOperation::iMsvSession | |
CMsvOperation::iMtm | |
CMsvOperation::iObserverRequestStatus | |
CMsvOperation::iService |
Inherited Enumerations | |
---|---|
CActive:TPriority |
Utility to create a messaging operation object for an operation that has already completed.
This utility is useful, for example, for writers of MTMs, where the API requires that an asynchronous operation is returned, but where in reality, the operation has performed synchronously. It allows the program to construct an operation object for which the operation is already completed, with the progress information and error code set.
IMPORT_C | ~CMsvCompletedOperation | ( | ) |
Destructor.
Any active request on the object is cancelled.
const TDesC8 & | FinalProgress | ( | ) | [virtual] |
Reimplemented from CMsvOperation::FinalProgress()
Gets information about a completed operation.
See also: CMsvOperation::FinalProgress()
IMPORT_C CMsvCompletedOperation * | NewL | ( | CMsvSession & | aMsvSession, |
TUid | aMtm, | |||
const TDesC8 & | aProgress, | |||
TMsvId | aService, | |||
TRequestStatus & | aObserverRequestStatus, | |||
TInt | aErr = KErrNone | |||
) | [static] |
Allocates and constructs a new CMsvCompletedOperation object.
The new object is added to the active scheduler and its asynchronous request immediately set to complete.
Parameters | |
---|---|
aMsvSession | Message Server session to use |
aMtm | The UID of the MTM associated with the operation. |
aProgress | Operation progress information buffer. This is copied by the object. |
aService | The ID of the service that is associated with this operation. |
aObserverRequestStatus | Request status of the operation observer. This observer is signalled that the operation is complete. |
aErr | Error code with which to complete the request. Use KErrNone to indicate that the operation completed successfully. |
Leave Codes | |
---|---|
KErrNoMemory |
const TDesC8 & | ProgressL | ( | ) | [virtual] |
Reimplemented from CMsvOperation::ProgressL()
Gets information on the progress of the operation.
For a CMsvCompletedOperation, the progress information returned by ProgressL() and FinalProgress() is the same, and is the progress information set in the NewL() function.
See also: CMsvOperation::ProgressL()