parseDouble static method

double? parseDouble(
  1. dynamic value
)

Implementation

static double? parseDouble(dynamic value){
  if(value==null) return null;
  if(value is int) return value.toDouble();
  if(value is double) return value;
  try{
    if(value is String) return double.parse(value);
  }catch(e){
    return null;
  }
}