State and Notifications Broker Usage Model

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

State and Notifications Broker provides a unified mechanism for storing device, application, and service states. It also provides a notification system. Applications get notified of changes to those states.

Provider Usage Model

The following list shows the steps in the provider process:

  1. A provider creates a registry key for all of the state properties that the service publishes. For each state property, the service creates a value in the registry under this key.
  2. The provider determines when a state property has changed and updates the registry with the new state property value.
  3. The State and Notifications Broker notifies all of the clients that registered for the notification.

Client Usage Model

The following list shows the steps in the client process:

  1. A client calls RegistryNotifyApp, RegistryNotifyWindow, RegistryNotifyCallback,or RegistryNotifyMsgQueue to register for a notification. The notifications can be a general notification of any change, or can be conditional on a comparison to a specified value.
  2. When a change notification arrives, the client is notified and can call RegistryGetDWORD or RegistryGetString to retrieve the new state.
  3. When the client no longer needs any notifications, the client calls RegistryCloseNotification to close transient notifications, or RegistryStopNotification to stop persistent notifications.

See Also

Reference

State and Notifications Broker Reference

Concepts

State and Notifications Broker Properties and Notification Types