UsernameValidator constructor

const UsernameValidator({
  1. int minLength = 3,
  2. int maxLength = 32,
  3. bool allowNumbers = true,
  4. bool allowUnderscore = false,
  5. bool allowDots = false,
  6. bool allowDash = false,
  7. bool allowSpace = false,
  8. bool allowSpecialChar = false,
  9. String? errorText,
  10. bool checkNullOrEmpty = true,
})

Constructor for the username validator.

Implementation

const UsernameValidator({
  this.minLength = 3,
  this.maxLength = 32,
  this.allowNumbers = true,
  this.allowUnderscore = false,
  this.allowDots = false,
  this.allowDash = false,
  this.allowSpace = false,
  this.allowSpecialChar = false,

  /// {@macro username_validator_error_text}
  super.errorText,

  /// {@macro base_validator_null_check}
  super.checkNullOrEmpty,
});