extractDoubleValue method
Extracts and validates a double value. Throws FormatException if value is not a number or not a double.
Implementation
@override
double extractDoubleValue(dynamic value, String errMsg) {
if (value is! num) {
throw FormatException(
"[JsonConverter] expected double, got ${value.runtimeType}: $errMsg",
);
}
if (value is! double) {
throw FormatException(
"[JsonConverter] expected double, got ${value.runtimeType}: $errMsg",
);
}
return value;
}