toDouble method
Returns either double
or null
.
"xyz".toDouble(); // null
"12.45".toDouble(); // 12.45
Implementation
double? toDouble() => double.tryParse(this);
Returns either double
or null
.
"xyz".toDouble(); // null
"12.45".toDouble(); // 12.45
double? toDouble() => double.tryParse(this);