toNumDouble property
double
get
toNumDouble
转为double类型
Implementation
double get toNumDouble {
if (this == null) {
return 0;
}
try {
if (this is double) {
return this as double;
} else {
return double.tryParse("$this") ?? 0;
}
} catch (e) {
return 0;
}
}