BasicValidators class
A class that provides basic common validation methods.
Constructors
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
-
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
Static Methods
-
confirmPassword(
String? value, String? original) → String? -
Validates that
valuematchesoriginal. -
email(
String? value) → String? -
Validates that the given
valueis a valid email address. -
password(
String? value, {int minLength = 8, bool requireUppercase = false, bool requireLowercase = false, bool requireNumber = false, bool requireSpecialChar = false}) → String? -
Validates that the given
valuemeets password strength requirements. -
pattern(
String? value, Pattern pattern, {String errorMessage = 'Invalid format', String fieldName = 'Field'}) → String? -
Validates that the given
valuematches the providedpattern. -
required(
String? value, {String fieldName = 'Field'}) → String? -
Validates that the given
valueis not null or empty. -
url(
String? value, {bool requireScheme = true}) → String? -
Validates that the given
valueis a valid URL.