CM_Get_Device_Interface_List function
The CM_Get_Device_Interface_List function retrieves a list of device interface instances that belong to a specified device interface class.
Syntax
CMAPI CONFIGRET WINAPI CM_Get_Device_Interface_List( _In_ LPGUID InterfaceClassGuid, _In_opt_ DEVINSTID_W pDeviceID, _Out_ PWCHAR Buffer, _In_ ULONG BufferLen, _In_ ULONG ulFlags );
Parameters
- InterfaceClassGuid [in]
-
Supplies a GUID that identifies a device interface class.
- pDeviceID [in, optional]
-
Caller-supplied pointer to a NULL-terminated string that represents a device instance ID. If specified, the function retrieves device interfaces that are supported by the device for the specified class. If this value is NULL, or if it points to a zero-length string, the function retrieves all interfaces that belong to the specified class.
- Buffer [out]
-
Caller-supplied pointer to a buffer that receives multiple, NULL-terminated Unicode strings, each representing the symbolic link name of an interface instance.
- BufferLen [in]
-
Caller-supplied value that specifies the length, in characters, of the buffer pointed to by Buffer. Call CM_Get_Device_Interface_List_Size to determine the required buffer size.
- ulFlags [in]
-
Contains one of the following caller-supplied flags:
- CM_GET_DEVICE_INTERFACE_LIST_ALL_DEVICES
-
The function provides a list containing device interfaces associated with all devices that match the specified GUID and device instance ID, if any.
- CM_GET_DEVICE_INTERFACE_LIST_PRESENT
-
The function provides a list containing device interfaces associated with devices that are currently active, and which match the specified GUID and device instance ID, if any.
Return value
If the operation succeeds, the function returns CR_SUCCESS. Otherwise, it returns one of the error codes with the CR_ prefix as defined in Cfgmgr32.h.
Remarks
Requirements
|
Target platform | |
|---|---|
|
Version |
Available in Microsoft Windows 2000 and later versions of Windows. |
|
Header |
|
|
Library |
|
|
DLL |
|
|
Unicode and ANSI names |
CM_Get_Device_Interface_ListW (Unicode) and CM_Get_Device_Interface_ListA (ANSI) |
See also