Class: LIBUSB::Bos::ContainerId
- Inherits:
-
FFI::ManagedStruct
- Object
- FFI::ManagedStruct
- LIBUSB::Bos::ContainerId
- Includes:
- GenericMethods
- Defined in:
- lib/libusb/bos.rb
Overview
A structure representing the Container ID descriptor. This descriptor is documented in section 9.6.2.3 of the USB 3.0 specification. All multiple-byte fields, except UUIDs, are represented in host-endian format.
Instance Method Summary collapse
-
#bReserved ⇒ Object
Reserved field.
-
#container_id ⇒ String
128 bit UUID.
- #inspect ⇒ Object
Methods included from GenericMethods
#bDescriptorType, #bDevCapabilityType, #bLength, #dev_capability_data
Instance Method Details
#bReserved ⇒ Object
Reserved field
201 202 203 |
# File 'lib/libusb/bos.rb', line 201 def bReserved self[:bReserved] end |
#container_id ⇒ String
Returns 128 bit UUID.
206 207 208 |
# File 'lib/libusb/bos.rb', line 206 def container_id self[:ContainerID].to_ptr.read_bytes(16) end |
#inspect ⇒ Object
210 211 212 |
# File 'lib/libusb/bos.rb', line 210 def inspect "\#<#{self.class} #{container_id.unpack("H*")[0]}>" end |