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_C CServShutdownSession ( ) [protected]

~CServShutdownSession()

IMPORT_C ~CServShutdownSession ( )

Member Functions Documentation

ClientThreadId()

TThreadId ClientThreadId ( ) const

DoServiceL(const RMessage2 &, TBool &)

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

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

Parameters

const RMessage2 & aMessage The client's message
TBool & aCompleteRequest An 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)

void NotifySave ( MSaveObserver::TSaveType aSaveType )

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

Parameters

MSaveObserver::TSaveType aSaveType The type of the requested save action.

PowerOffL(const RMessage2 &)

void PowerOffL ( 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 & aMessage The message containing the client request.

PowerStateL(const RMessage2 &)

void PowerStateL ( 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 & aMessage The message containing the client request.

RequestNotifyPowerDown(const RMessage2 &)

void RequestNotifyPowerDown ( 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 & aMessage The message containing the client request.

RequestNotifyPowerDownCancel()

void RequestNotifyPowerDownCancel ( ) [private]

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

ServiceL(const RMessage2 &)

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

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

Parameters

const RMessage2 & aMessage The message containing the client request.

Member Data Documentation

TInt iCurrentEvent

TInt iCurrentEvent [private]

TInt iOutstandingEvent

TInt iOutstandingEvent [private]

RMessagePtr2 iPtr

RMessagePtr2 iPtr [private]