isDigitOnly method

bool isDigitOnly()

Implementation

bool isDigitOnly() {
  if (this == null) return false;

  for (int i = 0; i < this!.length; i++) {
    bool isDigit = this![i].containsDigit();
    if (!isDigit) return false;
  }

  return true;
}