printBytes method
Implementation
@override
Future<void> printBytes({required List<int> bytes, required Printer printer}) async {
switch (printer.type) {
case PrinterType.usb:
await _usbRepository.printBytes(bytes: bytes, printer: printer);
break;
case PrinterType.bluethoot:
if (Platform.isWindows) {
throw UnimplementedError('Bluetooth printing is not supported on Windows');
}
await _bluetoothRepository.printBytes(bytes: bytes, printer: printer);
break;
case PrinterType.network:
await _networkRepository.printBytes(bytes: bytes, printer: printer);
break;
}
}