BACtrackStatus class
BACtrackStatus objects are emitted on the FlutterBactrack.statusStream. Not all states have an associated message. In these cases the message string is empty, it will never be null.
Where states have associated message strings in the BACtrackStatus object, these strings are noted below.
BACtrackState | Value of Message String |
---|---|
apiKeyDeclined | error message |
apiKeyAuthorized | empty |
didConnect | device name |
connected | device type |
disconnected | empty |
connectionTimeout | empty |
foundBreathalyzer | device identifier |
countDown | current countdown value, the est. time until blow (seconds) |
startBlowing | empty |
keepBlowing | empty |
analyzing | empty |
results | blood alcohol content, the decimal value as a string |
firmwareVersion | firmware version string |
serialNumber | serial number as hex string |
units | unit string |
useCount | use count as string |
batteryVoltage | voltage, decimal value as string |
batteryLevel | level, int value as string (0=low, 1=medium, >=2=high) |
error | error code, int value as string |
Constructors
- BACtrackStatus(BACtrackState state, {String message = ''})
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- message → String
-
Some states have string messages associated with them. See the documentation
for the BACtrackState enum for details. This string may be empty but will
never be null.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- state → BACtrackState
-
The current state of the API or device. States roughly correspond to method
names of the BACtrack SDK's callback object. See BACtrackState for details.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited