大网数据广告活动
网络与域名解析

Registering with the Routing Table Manager

· 52CE 我爱测

Before a client can access the routing table, it first must register with the routing table manager using the RtmRegisterEntity function.

Before a client can access the routing table, it first must register with the routing table manager using the RtmRegisterEntity function.

When a client registers, it passes to the routing table manager an RTM_ENTITY_INFO structure. This structure contains the information that uniquely identifies a client, the address family, and the instance of the routing table manager with which the client is registering. A client can also establish the RTM_EVENT_CALLBACK callback. The routing table manager will use this callback to notify the client of events such as change notifications and client registrations.

The routing table manager completes its registration processing and returns a handle to the client. The client must use this handle for all subsequent calls to RTMv2 functions.

The RtmRegisterEntity function that is used in RTMv2 is analogous to the RtmRegisterClient function that is used in RTMv1. The RtmRegisterClient function is obsolete, except for clients using IPX.

Once a client has finished interacting with the routing table manager, it must call RtmDeregisterEntity. The routing table manager destroys the handle associated with the client. To avoid memory leaks, the client must ensure that it releases all handles and deletes all the routes and next hops that it owns before calling RtmDeregisterEntity.

For sample code that shows how to use these functions, see Register with the Routing Table Manager and Use the Event Notification Callback.

Source: Microsoft Learn / Windows Win32 documentation by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / Windows Win32 documentation
适用范围
Windows Win32 API · Source date 05/31/2018
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。