原文来自MSDN Library for Visual Studio 2008 SP1,翻译部分仅为个人观点,想要看更多信息请看MSDN,如有版权问题请联系QQ 643166601,邮件643166601@qq.com
IWbemLocator Interface
Use the IWbemLocator interface to obtain the initial namespace pointer to the IWbemServices interface for WMI on a specific host computer.
使用IWbemLocator接口去取回初始化的命名空间指向的在一个指定主机计算机上的WMI接口的IWbemServices。
You can access Windows Management itself using the IWbemServices pointer, which is returned by the IWbemLocator::ConnectServer method.
你可以使用IWbemServices访问Windows管理它自己,通过IWbemLocator::ConnectServer方法返回。
A client or provider that requires Windows Management services first obtains a pointer to the locator using CoCreateInstance or CoCreateInstanceEx, as specified in the COM documentation in the Microsoft Windows Software Development Kit (SDK).
一个客户端或提供者请求Windows管理服务首先使用CoCreateInstance 或 CoCreateInstanceEx 取回一个指向到定位,作为在Microsoft Windows软件开发包(SDK)中COM的参考资料。
The IWbemLocator object is always an in-process COM server.
这个IWbemLocator对象总是在一个进程内的COM服务器。
The interface pointer to the desired namespace on the desired target computer is then obtained through the IWbemLocator::ConnectServer method, which is the only method on this interface.
这个接口指向在渴望的目标计算机上的一个被渴望的命名空间然后通过IWbemLocator::ConnectServer方法取回,它是在这个接口上的唯一的方法。
Methods in Vtable Order
The IWbemLocator interface inherits the methods of the IUnknown interface.
这个IWbemLocator接口继承IUnknown接口的方法。
In addition, IWbemLocator defines the following method.
此外,IWbemLocator定义了以下方法。
Method Description
ConnectServer
Connects to Windows Management on the specified computer.
连接到指定计算机上的Windows管理。
Requirements
Client
Requires Windows Vista, Windows XP, Windows 2000 Professional, Windows NT Workstation 4.0 SP4 and later, Windows Me, Windows 98, or Windows 95.
Server
Requires Windows Server 2008, Windows Server 2003, Windows 2000 Server, or Windows NT Server 4.0 SP4 and later.
Header
Declared in Wbemcli.h; include Wbemidl.h.
Library
Use Wbemuuid.lib.
DLL
Requires Wbemcore.dll.
Requires Wbemupgd.dll.
Send comments about this topic to Microsoft
Build date: 8/15/2007