Struct libusb::Device [] [src]

pub struct Device<'a> {
    // some fields omitted
}

A reference to a USB device.

Methods

impl<'a> Device<'a>
[src]

fn device_descriptor(&self) -> Result<DeviceDescriptor>

Reads the device descriptor.

fn config_descriptor(&self, config_index: u8) -> Result<ConfigDescriptor>

Reads a configuration descriptor.

fn active_config_descriptor(&self) -> Result<ConfigDescriptor>

Reads the configuration descriptor for the current configuration.

fn bus_number(&self) -> u8

Returns the number of the bus that the device is connected to.

fn address(&self) -> u8

Returns the device's address on the bus that it's connected to.

fn speed(&self) -> Speed

Returns the device's connection speed.

fn open(&self) -> Result<DeviceHandle<'a>>

Opens the device.

Trait Implementations

impl<'a> Drop for Device<'a>
[src]

fn drop(&mut self)

Releases the device reference.

impl<'a> Send for Device<'a>
[src]

impl<'a> Sync for Device<'a>
[src]