validate method

bool validate ()

Calls FormField.validator to set the errorText. Returns true if there were no errors.

Implementation

bool validate() {
  setState(() {
    _validate();
  });
  return !hasError;
}