checkLength method

void checkLength(
  1. int value,
  2. int maxLength
)

Implementation

void checkLength(int value, int maxLength) {
  if (value > maxLength) throw ArgumentError("Length $value too long for $runtimeType");
}