CServShutdownSession Class Reference

class CServShutdownSession : public CSession2

This class describes a server side session object, which handles reqistration requests of clients, which are interested in power down events.

Inherits from

Constructor & Destructor Documentation

CServShutdownSession()

IMPORT_CCServShutdownSession()[protected]

~CServShutdownSession()

IMPORT_C~CServShutdownSession()

Member Functions Documentation

ClientThreadId()

TThreadId ClientThreadId()const

DoServiceL(const RMessage2 &, TBool &)

voidDoServiceL(const RMessage2 &aMessage,
TBool &aCompleteRequest
)[private]

This method dispatches all client requests to the appropriate method calls.

Parameters

const RMessage2 & aMessageThe client's message
TBool & aCompleteRequestAn output parameter. If zero, the client request will be completed later.

HasPendingRequest()

TBool HasPendingRequest()const

NewL()

CServShutdownSession *NewL()[static]
Standard phase-one factor method for creating CServShutdownSession instances.
leave
KErrNoMemory Not enough memory to complete the operation.

NotifySave(MSaveObserver::TSaveType)

voidNotifySave(MSaveObserver::TSaveTypeaSaveType)

This method will complete the pending asychronous client request, effectivelly notifying it about the action, which the client has to do.

Parameters

MSaveObserver::TSaveType aSaveTypeThe type of the requested save action.

PowerOffL(const RMessage2 &)

voidPowerOffL(const RMessage2 &aMessage)[private]

This method should be used only with SYSLIBS_TEST macro defined and can be used to initiate a powerdown sequence. Without SYSLIBS_TEST macro defined the method will panic the client with KErrNotSupported error code.

Parameters

const RMessage2 & aMessageThe message containing the client request.

PowerStateL(const RMessage2 &)

voidPowerStateL(const RMessage2 &aMessage)const [private]

This method should be used only with SYSLIBS_TEST macro defined and can be used to get the power state of the server. Without SYSLIBS_TEST macro defined the method will panic the client with KErrNotSupported error code.

Parameters

const RMessage2 & aMessageThe message containing the client request.

RequestNotifyPowerDown(const RMessage2 &)

voidRequestNotifyPowerDown(const RMessage2 &aMessage)[private]

This method processes a client-side registration request. It is an asynchronous request, which will be completed later, when powerdown/low memory event occurs.

Parameters

const RMessage2 & aMessageThe message containing the client request.

RequestNotifyPowerDownCancel()

voidRequestNotifyPowerDownCancel()[private]

This method cancels the client registration, completing the requests with KErrCancel error code.

ServiceL(const RMessage2 &)

IMPORT_C voidServiceL(const RMessage2 &aMessage)[protected, virtual]

Handles the servicing of client requests passed to the shutdown server.

Parameters

const RMessage2 & aMessageThe message containing the client request.

Member Data Documentation

TInt iCurrentEvent

TInt iCurrentEvent[private]

TInt iOutstandingEvent

TInt iOutstandingEvent[private]

RMessagePtr2 iPtr

RMessagePtr2 iPtr[private]