UsbSerialPlatform class abstract base

The platform side of skio_usb_serial.

Apps don't use this directly; they use UsbSerialPort. Tests can replace instance with a fake to exercise app code without hardware.

Implemented types
Implementers

Constructors

UsbSerialPlatform()
Constructor for subclasses.

Properties

events → Stream<DeviceEvent>
Attach and detach events.
no setter
hashCode → int
The hash code for this object.
no setterinherited
requiresUserSelection → bool
Whether the user must pick a port in a system chooser (request) before it appears in list. True on the web.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

checkAccess([DeviceHandle? device]) → Future<AccessReport>
Returns the current access state without showing any prompt.
inherited
list() → Future<List<DeviceHandle>>
Serial ports currently attached (Android) or already granted (web).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
open(DeviceHandle device, SerialConfig config) → Future<SerialConnection>
Opens device with config.
openSettings() → Future<bool>
Opens this app's page in the system settings.
inherited
request(List<DeviceFilter> filters) → Future<DeviceHandle?>
Shows the system port chooser, if the platform has one.
requestAccess([DeviceHandle? device]) → Future<AccessReport>
Requests access, which may show system dialogs.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

instance ↔ UsbSerialPlatform
The active platform implementation.
getter/setter pair