Skip to content

Latest commit

 

History

History
171 lines (127 loc) · 5.76 KB

nc-rtmv2-_event_callback.md

File metadata and controls

171 lines (127 loc) · 5.76 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NC:rtmv2._EVENT_CALLBACK
_EVENT_CALLBACK (rtmv2.h)
The RTM_EVENT_CALLBACK callback is used by the routing table manager to inform a client that the specified event occurred.
RTM_CHANGE_NOTIFICATION
RTM_ENTITY_DEREGISTERED
RTM_ENTITY_REGISTERED
RTM_EVENT_CALLBACK
RTM_EVENT_CALLBACK callback function [RAS]
RTM_EVENT_CALLBACK callback function pointer [RAS]
RTM_ROUTE_EXPIRED
_EVENT_CALLBACK
_EVENT_CALLBACK callback
_rtmv2ref_rtm_event_callback
rras.rtm_event_callback
rtmv2/RTM_EVENT_CALLBACK
rras\rtm_event_callback.htm
RRAS
57179cea-d92b-4199-bb61-b34d980532cf
12/05/2018
RTM_CHANGE_NOTIFICATION, RTM_ENTITY_DEREGISTERED, RTM_ENTITY_REGISTERED, RTM_EVENT_CALLBACK, RTM_EVENT_CALLBACK callback function [RAS], RTM_EVENT_CALLBACK callback function pointer [RAS], RTM_ROUTE_EXPIRED, _EVENT_CALLBACK, _EVENT_CALLBACK callback, _rtmv2ref_rtm_event_callback, rras.rtm_event_callback, rtmv2/RTM_EVENT_CALLBACK
rtmv2.h
Windows
None supported
Windows 2000 Server [desktop apps only]
Windows
19H1
_EVENT_CALLBACK
rtmv2/_EVENT_CALLBACK
c++
APIRef
kbSyntax
UserDefined
Rtmv2.h
RTM_EVENT_CALLBACK

_EVENT_CALLBACK callback function

-description

The RTM_EVENT_CALLBACK callback is used by the routing table manager to inform a client that the specified event occurred.

-parameters

-param RtmRegHandle

Handle to the client to which the routing table manager is sending the notification.

-param EventType

Specifies the event about which the routing table manager is notifying the client. The following values are used.

Value Meaning
RTM_ENTITY_REGISTERED
A client has just registered with the routing table manager.
RTM_ENTITY_DEREGISTERED
A client has just unregistered.
RTM_ROUTE_EXPIRED
A route has timed out.
RTM_CHANGE_NOTIFICATION
A change notification has been made.

-param Context1

For RTM_ENTITY_REGISTERED calls: Contains the handle to the entity that registered.

For RTM_ENTITY_DEREGISTERED calls: Contains the handle to the entity that unregistered.

For RTM_ROUTE_EXPIRED calls: Contains the handle to the route that timed out.

For RTM_CHANGE_NOTIFICATION calls: Contains the handle to the change notification.

-param Context2

For RTM_ENTITY_REGISTERED calls: Contains a pointer to the RTM_ENTITY_INFO structure referred to by the handle in Context1. If the client must retain this information, the client must copy it to a structure it has allocated.

For RTM_ENTITY_DEREGISTERED calls: Contains a pointer to the RTM_ENTITY_INFO structure referred to by the handle in Context1. If the client must retain this information, the client must copy it to a structure it has allocated.

For RTM_ROUTE_EXPIRED calls: Contains a pointer to the RTM_ROUTE_INFO structure referred to by the handle in Context1. If the client must retain this information, the client must copy it to a structure it has allocated.

For RTM_CHANGE_NOTIFICATION calls: Contains the notification context that was given to the client by a previous call to RtmRegisterForChangeNotification.

-returns

If the routing table manager issues an RTM_ROUTE_EXPIRED callback, and the client returns to the routing table manager the value ERROR_NOT_SUPPORTED, the routing table manager will delete the route from the routing table.

All other errors returned by the client are ignored.

-remarks

After a client has registered for change notification, the routing table manager uses this callback to keep the client informed about events.

If a client receives an RTM_EVENT_CALLBACK for the RTM_ENTITY_REGISTERED or RTM_ENTITY_DEREGISTERED events, the client must not make calls to RtmRegisterEntity, RtmDeregisterEntity, or RtmGetRegisteredEntities in the context of this callback.

If a client receives an RTM_EVENT_CALLBACK for the RTM_CHANGE_NOTIFICATION event, the client must not call RtmRegisterForChangeNotification in the context of this callback.

-see-also

RTM_EVENT_TYPE

RtmRegisterEntity