RequiredValidator class
A class that represents a required field validator.
This class extends the BaseValidator class and is specifically designed to validate that a field is not empty.
- Inheritance
-
- Object
- BaseValidator
- RequiredValidator
Constructors
- RequiredValidator({String? fieldName})
Properties
- displayedError → String
-
Returns the error message to be displayed.
no setterinherited
- errorMessage → String
-
finalinherited
- fieldName → String?
-
finalinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- validation → bool Function(String)?
-
finalinherited
Methods
-
isValid(
dynamic value) → bool -
Checks if the value is valid.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited