OnDemandRegisterNotification function (ondemandconnroutehelper.h)

The OnDemandRegisterNotification function allows an application to register to be notified when the Route Requests cache is modified. For example, this allows the system to recycle cached connections when a Route Request is added or removed from the cache.

Syntax

HRESULT OnDemandRegisterNotification(
  [in]           ONDEMAND_NOTIFICATION_CALLBACK callback,
  [in, optional] void                           *callbackContext,
  [out]          HANDLE                         *registrationHandle
);

Parameters

[in] callback

A pointer to a function of type ONDEMAND_NOTIFICATION_CALLBACK to receive the notifications.

[in, optional] callbackContext

A pointer to a memory location containing optional context to be passed to the callback.

[out] registrationHandle

A pointer to a HANDLE to receive a handle to the registration in case of success.

Return value

Returns S_OK on success.

Remarks

The ONDEMAND_NOTIFICATION_CALLBACK function is defined as:

typedef void (WINAPI *ONDEMAND_NOTIFICATION_CALLBACK) (PVOID);

Requirements

Requirement Value
Minimum supported client Windows 8.1 [desktop apps only]
Minimum supported server Windows Server 2012 R2 [desktop apps only]
Target Platform Windows
Header ondemandconnroutehelper.h
Library OnDemandConnRouteHelper.lib
DLL OnDemandConnRouteHelper.dll

See also

OnDemandUnregisterNotification