EndpointDescriptor constructor

EndpointDescriptor({
  1. required int address,
  2. required TransferType type,
  3. required Direction direction,
  4. required int maximumPacketSize,
  5. SynchronizationType? synchronization,
  6. UsageType? usage,
  7. int? pollingInterval,
  8. required ByteBuffer extraData,
})

Implementation

EndpointDescriptor({
  /// Endpoint address.
  required int address,

  /// Transfer type.
  required TransferType type,

  /// Transfer direction.
  required Direction direction,

  /// Maximum packet size.
  required int maximumPacketSize,

  /// Transfer synchronization mode (isochronous only).
  SynchronizationType? synchronization,

  /// Endpoint usage hint.
  UsageType? usage,

  /// Polling interval (interrupt and isochronous only).
  int? pollingInterval,

  /// Extra descriptor data associated with this endpoint.
  required ByteBuffer extraData,
}) : _wrapped = $js.EndpointDescriptor(
        address: address,
        type: type.toJS,
        direction: direction.toJS,
        maximumPacketSize: maximumPacketSize,
        synchronization: synchronization?.toJS,
        usage: usage?.toJS,
        pollingInterval: pollingInterval,
        extra_data: extraData.toJS,
      );