doubleValue method

  1. @override
double doubleValue(
  1. Unit unit
)
override

Returns the value of this measurable stated in the specified unit as a double.

Implementation

@override
double doubleValue(Unit unit) {
  if (unit == this.unit) return value.toDouble();
  return this.unit.getConverterTo(unit).convert(value.toDouble());
}