RDmDomain Class Reference

class RDmDomain

The application's interface to the domain manager.

Member Functions Documentation

AcknowledgeLastState()

IMPORT_C void AcknowledgeLastState ( )

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 void AcknowledgeLastState ( TInt aError )

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 aError KDmErrNotJoin if domain is not part of the hierarhcy or a system wide error value associated with the state change.

CancelTransitionNotification()

IMPORT_C void CancelTransitionNotification ( )

Cancels an outstanding notification request.

Any outstanding notification request completes with KErrCancel.

Close()

IMPORT_C void Close ( )

Disconnects from the associated domain.

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

Connect(TDmDomainId)

IMPORT_C TInt Connect ( TDmDomainId aId )

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 aId The identifier of the domain to be connected to.

Connect(TDmHierarchyId, TDmDomainId)

IMPORT_C TInt Connect ( TDmHierarchyId aHierarchyId,
TDmDomainId aDomainId
)

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 aHierarchyId The Id of the domain hierarchy to connect to.
TDmDomainId aDomainId The identifier of the domain to be connected to.

GetPowerState()

IMPORT_C TPowerState GetPowerState ( )

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 TDmDomainState GetState ( )

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 void RequestTransitionNotification ( 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 & aStatus The 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]