HoverValidator class abstract

Implementers

Constructors

HoverValidator()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addRule(HoverValidationRule validationRule) HoverValidator
Add a custom validation rule.
build() String? Function(String)
Generates the validation function.
check(String valueToValidate) bool
Checks if the input is valid based on the validation rules provided.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
validate(String valueToValidate) String?
Returns validation error messages as a single string joined with the newline character if the input valueToValidate does not pass validation and returns null otherwise.
validateAsEmail() HoverValidator
Adds a rule that will validate that the input string is a valid email address.
validateAsMobileNumber() HoverValidator
Adds a rule that will validate that the input string is a valid mobile number.
validateAsPassword(int passwordMinLength, {bool mustContainUppercase = false, bool mustContainLowercase = false, bool mustContainNumber = false}) HoverValidator
Adds a rule that will ensure the input meets a minimum password length passwordMinLength. Can also be configured to require uppercase letters, lowercase letters, or special characters.
validateAsPasswordConfirmation(String passwordConfirmation) HoverValidator
Adds a rule that will ensure the input matches the passwordConfirmation value.
validateAsRequired() HoverValidator
Adds a rule that will ensure the input is not null.
validateWithErrorsAsList(String valueToValidate) List<String>?
Returns validation error messages as a list of strings if the input valueToValidate does not pass validation and returns null otherwise.

Operators

operator ==(Object other) bool
The equality operator.
inherited