PrinterLabelPlatform class abstract

Inheritance
  • Object
  • PlatformInterface
  • PrinterLabelPlatform
Implementers

Constructors

PrinterLabelPlatform()

Properties

bluetoothScanStream Stream<BluetoothDeviceModel>
Stream các device được discover trong quá trình scan. Gọi startBluetoothScan trước khi listen trên iOS.
no setter
hashCode int
The hash code for this object.
no setterinherited
platformVersion Future<String?>
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
usbDeviceStream Stream<UsbConnectionEvent>
no setter

Methods

checkConnect({String? deviceId}) Future<bool>
connectBluetooth({required String macAddress}) Future<bool>
identifier trên iOS là UUID string của CBPeripheral. Trên Android là MAC address. Giữ tên param là macAddress để tương thích backward.
connectLan({required String ipAddress}) Future<bool>
disconectPrinter({String? deviceId}) Future<bool>
getAllConnections() Future<Map<String, bool>>
getBluetoothDevices() Future<List<BluetoothDeviceModel>>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
printAll({LabelModel? labelModel, PrintThermalModel? escModel, PrinterConnectionType? connectionType}) Future<void>
printBarcode({String? deviceId, PrinterConnectionType? connectionType, required BarcodeModel printBarcodeModel}) Future<void>
printESC({String? deviceId, PrinterConnectionType? connectionType, required PrintThermalModel printThermalModel}) Future<void>
printImage({String? deviceId, PrinterConnectionType? connectionType, required ImageModel imageModel}) Future<void>
printLabel({String? deviceId, PrinterConnectionType? connectionType, required LabelModel labelModel}) Future<void>
startBluetoothScan() Future<bool>
iOS: bắt đầu scan BLE — devices stream qua bluetoothScanStream Android: no-op (Android tự scan)
stopBluetoothScan() Future<bool>
toString() String
A string representation of this object.
inherited

Operators

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

Static Properties

instance PrinterLabelPlatform
getter/setter pair