parseDoubleList static method

List<double>? parseDoubleList(
  1. dynamic value
)

Parses the dynamic value into a List of double values. The value may be null, in which case null will be returned, or it may be an array of any type, but each element in the array must be parsable into a valid double or an error will be thrown.

Implementation

static List<double>? parseDoubleList(dynamic value) {
  List<double>? result;

  if (value is List) {
    result = [];
    for (var v in value) {
      result.add(parseDouble(v)!);
    }
  }

  return result;
}