27 lines
632 B
Dart
27 lines
632 B
Dart
import 'package:flutter_blue_plus/flutter_blue_plus.dart';
|
|
|
|
class ScanDeviceInfo {
|
|
//设备名字
|
|
final String advName;
|
|
|
|
// 是否绑定
|
|
final bool isBinding;
|
|
// 是否有新事件
|
|
final bool hasNewEvent;
|
|
|
|
// 原始设备信息
|
|
final ScanResult rawDeviceInfo;
|
|
|
|
ScanDeviceInfo({
|
|
required this.advName,
|
|
this.isBinding = false, // 默认值为 false
|
|
this.hasNewEvent = false, // 默认值为 false
|
|
required this.rawDeviceInfo,
|
|
});
|
|
|
|
@override
|
|
String toString() {
|
|
return 'ScanDeviceInfo{advName: $advName, isBinding: $isBinding, hasNewEvent: $hasNewEvent,rawDeviceInfo:$rawDeviceInfo}';
|
|
}
|
|
}
|