Package oshi.hardware.platform.windows
Class WindowsUsbDevice
java.lang.Object
oshi.hardware.common.AbstractUsbDevice
oshi.hardware.platform.windows.WindowsUsbDevice
- All Implemented Interfaces:
Comparable<UsbDevice>
,UsbDevice
Windows Usb Device
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final com.sun.jna.platform.win32.Guid.GUID
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
addDevicesToList
(List<UsbDevice> deviceList, List<UsbDevice> list) getUsbDevices
(boolean tree) Instantiates a list ofUsbDevice
objects, representing devices connected via a usb port (including internal devices).private static WindowsUsbDevice
queryDeviceAndChildren
(Integer device, Map<Integer, Integer> parentMap, Map<Integer, String> nameMap, Map<Integer, String> deviceIdMap, Map<Integer, String> mfgMap, String vid, String pid, String parentSerial) Methods inherited from class oshi.hardware.common.AbstractUsbDevice
compareTo, getConnectedDevices, getName, getProductId, getSerialNumber, getUniqueDeviceId, getVendor, getVendorId, toString
-
Field Details
-
GUID_DEVINTERFACE_USB_HOST_CONTROLLER
private static final com.sun.jna.platform.win32.Guid.GUID GUID_DEVINTERFACE_USB_HOST_CONTROLLER
-
-
Constructor Details
-
WindowsUsbDevice
-
-
Method Details
-
getUsbDevices
Instantiates a list ofUsbDevice
objects, representing devices connected via a usb port (including internal devices).If the value of
tree
is true, the top level devices returned from this method are the USB Controllers; connected hubs and devices in its device tree share that controller's bandwidth. If the value oftree
is false, USB devices (not controllers) are listed in a single flat list.- Parameters:
tree
- If true, returns a list of controllers, which requires recursive iteration of connected devices. If false, returns a flat list of devices excluding controllers.- Returns:
- a list of
UsbDevice
objects.
-
addDevicesToList
-
queryUsbDevices
-
queryDeviceAndChildren
-