isListOfPairs static method

bool isListOfPairs(
  1. Iterable list
)

Returns true if list is a List of paris.

Implementation

static bool isListOfPairs(Iterable list) {
  if (list.isEmpty) return false;
  return listMatchesAll(
      list,
      (dynamic e) =>
          e is List && e.length == 2 && listMatchesAll(e, isValidValue));
}