RDmDomain Class Reference

class RDmDomain

The application's interface to the domain manager.

Member Functions Documentation

AcknowledgeLastState()

IMPORT_C voidAcknowledgeLastState()

Acknowledges the state change.

An application must acknowledge that it has performed all actions required by the last known state of the domain.

AcknowledgeLastState(TInt)

IMPORT_C voidAcknowledgeLastState(TIntaError)

Acknowledges the state change with the specified error

An application must acknowledge that it has performed all actions required by the last known state of the domain.

Parameters

TInt aErrorKDmErrNotJoin if domain is not part of the hierarhcy or a system wide error value associated with the state change.

CancelTransitionNotification()

IMPORT_C voidCancelTransitionNotification()

Cancels an outstanding notification request.

Any outstanding notification request completes with KErrCancel.

Close()

IMPORT_C voidClose()

Disconnects from the associated domain.

If this object is not connected to any domain, then it returns silently.

Connect(TDmDomainId)

IMPORT_C TIntConnect(TDmDomainIdaId)

Connects to the domain identified by the specified domain Id.

To connect to the root domain, which has the Id KDmIdRoot, the capability WriteDeviceData is required.

Once connected, an application can use this RDmDomain object to read the domain's power state and to request notification when the power state changes.

capability
WriteDeviceData If aDomainId==KDmIdRoot

Parameters

TDmDomainId aIdThe identifier of the domain to be connected to.

Connect(TDmHierarchyId, TDmDomainId)

IMPORT_C TIntConnect(TDmHierarchyIdaHierarchyId,
TDmDomainIdaDomainId
)

Connects to the domain identified by the specified domain Id.

To connect to the root domain, which has the Id KDmIdRoot, the capability WriteDeviceData is required.

Once connected, an application can use this RDmDomain object to read the domain's state and to request notification when the state changes.

capability
WriteDeviceData If aDomainId==KDmIdRoot

Parameters

TDmHierarchyId aHierarchyIdThe Id of the domain hierarchy to connect to.
TDmDomainId aDomainIdThe identifier of the domain to be connected to.

GetPowerState()

IMPORT_C TPowerStateGetPowerState()

Gets the domain's power state.

An application normally calls this function after a notification request has completed. It then performs any application-dependent action demanded by the power state, and then acknowledges the state transition.

Note that the domain manager requires any domain power state change to be acknowledged by all applications connected to the domain.

RDmDomain::AcknowledgeLastState()

GetState()

IMPORT_C TDmDomainStateGetState()

Gets the domain's state.

An application normally calls this function after a notification request has completed. It then performs any application-dependent action demanded by the state, and then acknowledges the state transition.

Note, that the domain manager requires any domain state change to be acknowledged by all applications connected to the domain.

RequestTransitionNotification(TRequestStatus &)

IMPORT_C voidRequestTransitionNotification(TRequestStatus &aStatus)

Requests notification when the domain's state changes.

This is an asynchronous request that completes when the domain's state changes.

RDmDomain::CancelTransitionNotification()

Parameters

TRequestStatus & aStatusThe request status object for this asynchronous request.

Member Data Documentation

TInt iLastStatePropertyValue

TInt iLastStatePropertyValue[private]

RDmDomainSession iSession

RDmDomainSession iSession[private]

RProperty iStateProperty

RProperty iStateProperty[private]