toDoubleOrNull static method
Implementation
static double? toDoubleOrNull(dynamic value) {
if (value is double) {
return value;
} else if (value is int) {
return value.toDouble();
} else if (value is String) {
return double.tryParse(value);
}
return null;
}