Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: ScheduleBaseServerMtm.h
Link against: schsend.lib

This item is not part of the S60 3rd Edition SDK for Symbian OS, Feature Pack 2.

Class CScheduleBaseServerMtm

class CScheduleBaseServerMtm : public CBaseServerMtm;

Description

Base class for Server MTMs that support scheduling.

It contains pure virtual functions which must be implemented by the Server MTM. These functions are not required for interoperability with any other classes, however they are essential functionality that must be implemented by a Server MTM that support scheduling.

CScheduleBaseServerMtm uses a class derived from CMsvScheduleSend to interface with the task scheduler.

Derivation

Members

Defined in CScheduleBaseServerMtm:
CScheduleBaseServerMtm(), CheckScheduleL(), ConstructL(), DeleteScheduleL(), LoadResourceFileL(), LoadResourceFileL(), LoadScheduleSettingsL(), PopulateSchedulePackage(), Queue(), ScheduleL(), SendScheduledL(), iFs, iReport, iResourceFile, iScheduleSend, ~CScheduleBaseServerMtm()

Inherited from CActive:
Cancel(), Deque(), DoCancel(), EPriorityHigh, EPriorityIdle, EPriorityLow, EPriorityStandard, EPriorityUserInput, IsActive(), IsAdded(), Priority(), SetActive(), SetPriority(), TPriority, iStatus

Inherited from CBase:
Delete(), operator new()

Inherited from CBaseServerMtm:
ChangeL(), CommandExpected(), CopyFromLocalL(), CopyToLocalL(), CopyWithinServiceL(), CreateL(), DeleteAllL(), DoComplete(), DoRunL(), Extension_(), GetInterface(), MoveFromLocalL(), MoveToLocalL(), MoveWithinServiceL(), Progress(), RunError(), RunL(), StartCommandL(), SystemProgress(), iServerEntry

See also:


Construction and destruction


CScheduleBaseServerMtm()

protected: IMPORT_C CScheduleBaseServerMtm(CRegisteredMtmDll &aRegisteredMtmDll, CMsvServerEntry *aServerEntry);

Description

Constructor.

Parameters

CRegisteredMtmDll &aRegisteredMtmDll

Registration data for the MTM DLL

CMsvServerEntry *aServerEntry

Context on which to operate


ConstructL()

protected: virtual IMPORT_C void ConstructL();

Description

Second phase constructor.

This calls LoadResourceFileL().

The derived class second phase constructor should call this function. It should also construct the iScheduleSend member.

Leave codes

Leaves

with one of the system-wide error if unable to connect to the file server

LoadResourceFileL()


~CScheduleBaseServerMtm()

protected: IMPORT_C ~CScheduleBaseServerMtm();

Description

Destructor.

The derived class destructor should delete the iScheduleSend member.

[Top]


Member functions


SendScheduledL()

protected: virtual IMPORT_C void SendScheduledL(CMsvEntrySelection &aSelection, const TBool aMove, const TDesC8 &aParameter, TRequestStatus &aStatus);

Description

Sends messages now that were previously scheduled.

The messages are sent immediately, overriding the scheduling.

Parameters

CMsvEntrySelection &aSelection

The selection of messages that were previously scheduled and now need to be sent

const TBool aMove

Whether to perform a Move (ETrue) or a Copy (EFalse) when sending has completed

const TDesC8 &aParameter

The parameter (MTM-specific) that is required when sending the messages

TRequestStatus &aStatus

Asynchronous status word


ScheduleL()

protected: virtual IMPORT_C void ScheduleL(CMsvEntrySelection &aSelection, const TBool aMove, const TDesC8 &aParameter, TRequestStatus &aStatus);

Description

Schedules a message.

The functions should schedule a message using CMsvScheduleSend::ScheduleL(). Make sure RestoreScheduleSettingsL() is called before CMsvScheduleSend::ScheduleL().

Parameters

CMsvEntrySelection &aSelection

The selection of messages that need to be scheduled

const TBool aMove

Whether to perform a Move (ETrue) or a Copy (EFalse) when sending has completed

const TDesC8 &aParameter

The parameter (MTM-specific) that is required when sending the messages

TRequestStatus &aStatus

Asynchronous status word

Leave codes

CMsvScheduleSend::ScheduleL()


LoadResourceFileL()

protected: IMPORT_C void LoadResourceFileL(const TDesC &aResFileName);

Description

Loads the specified resource file.

A utility function that can be used from the pure virtual LoadResourceFileL().

It leaves if the resource file reader cannot be opened.

Parameters

const TDesC &aResFileName

Resource file name


CheckScheduleL()

protected: virtual IMPORT_C void CheckScheduleL(const CMsvEntrySelection &aSelection, const TDesC8 &aParameter, TRequestStatus &aStatus);

Description

Verifies that the schedule information stored in specified messages is the same as that on the task scheduler.

Parameters

const CMsvEntrySelection &aSelection

Array of message IDs that need to be checked against the task scheduler

const TDesC8 &aParameter

Unused

TRequestStatus &aStatus

Asynchronous status word

Leave codes

CMsvScheduleSend::CheckScheduleL()

See also:


DeleteScheduleL()

protected: virtual IMPORT_C void DeleteScheduleL(const CMsvEntrySelection &aSelection, const TDesC8 &aParameter, TRequestStatus &aStatus);

Description

Deletes the schedules for the specified messages from the task scheduler.

The messages themselves are not deleted.

Parameters

const CMsvEntrySelection &aSelection

Array of message IDs that need to be deleted from the task scheduler

const TDesC8 &aParameter

Unused

TRequestStatus &aStatus

Asynchronous status word

Leave codes

CMsvScheduleSend::DeleteScheduleL()

See also:


PopulateSchedulePackage()

protected: virtual void PopulateSchedulePackage(const TDesC8 &aParameter, const TBool aMove, TMsvSchedulePackage &aPackage) const=0;

Description

Populates a TMsvSchedulePackage object with scheduling information.

Parameters

const TDesC8 &aParameter

Parameter information for the package

const TBool aMove

Flag that signals whether a move or copy is required

TMsvSchedulePackage &aPackage

On return, a populated object


LoadResourceFileL()

protected: virtual void LoadResourceFileL()=0;

Description

Loads the resource file (if any) for the MTM.


Queue()

protected: IMPORT_C void Queue(TRequestStatus &aStatus);

Description

Specifies an asynchronous status word to be completed when an asynchronous MTM operation completes.

This provides a form of observer functionality. It sets the the iReport member.

Parameters

TRequestStatus &aStatus

Asynchronous status word to use

Panic codes

ScheduleSend-DLL

28 iReport member not NULL. Debug build only.


LoadScheduleSettingsL()

protected: IMPORT_C void LoadScheduleSettingsL(CRepository &aRepository, TBool aRestoreErrorsFromResource=EFalse, TInt aErrorsResourceId=0);

Description

Loads all the schedule settings either from CenRep or a resource file.

Parameters

CRepository &aRepository

CenRep repository to load settings from

TBool aRestoreErrorsFromResource

Whether to read error handling information (a SEND_ERROR_ACTIONS struct) from a resource file

TInt aErrorsResourceId

Resource ID of the error handling resource struct

Panic codes

ScheduleSend-DLL

24 The context is not a service entry

See also:

[Top]


Member data


iScheduleSend

protected: CMsvScheduleSend * iScheduleSend;

Description

Message scheduler.


iResourceFile

protected: RResourceFile iResourceFile;

Description

MTM resource file.


iFs

protected: RFs iFs;

Description

File server handle.


iReport

protected: TRequestStatus * iReport;

Description

Asynchronous status word.