equivalentTo method

  1. @override
bool equivalentTo(
  1. Data other
)
override

Returns true if the batteryLevel is equal.

Implementation

@override
bool equivalentTo(Data other) =>
    (other is BatteryState) ? batteryLevel == other.batteryLevel : false;