BleMtuEvent.fromMap constructor

BleMtuEvent.fromMap(
  1. Map map
)

Implementation

factory BleMtuEvent.fromMap(Map<dynamic, dynamic> map) => BleMtuEvent(
  remoteId: BleRemoteId(map[BleChannelKey.remoteId] as String? ?? ''),
  mtu: map[BleChannelKey.mtu] as int? ?? 23,
  success:
      map[BleChannelKey.success] == 1 || map[BleChannelKey.success] == true,
  errorCode: map[BleChannelKey.errorCode] as int? ?? 0,
  errorString: map[BleChannelKey.errorString] as String? ?? '',
);