UsbDeviceInfo.fromMap constructor
UsbDeviceInfo.fromMap(
- Map<String, dynamic> map
)
Implementation
factory UsbDeviceInfo.fromMap(Map<String, dynamic> map) {
return UsbDeviceInfo(
deviceId: map['deviceId'] as int? ?? -1,
deviceName: map['deviceName'] as String? ?? '',
vendorId: map['vendorId'] as int? ?? 0,
productId: map['productId'] as int? ?? 0,
manufacturerName: map['manufacturerName'] as String?,
productName: map['productName'] as String?,
serialNumber: map['serialNumber'] as String?,
hasPermission: map['hasPermission'] as bool? ?? false,
);
}