CustomPasswordRequirement class
Custom requirement from a description string and validator closure.
- Inheritance
-
- Object
- PasswordRequirement
- CustomPasswordRequirement
Constructors
- CustomPasswordRequirement({required String description, required bool validator(String password)})
- Creates a custom password requirement.
Properties
- description → String
-
The text description of the requirement (e.g., "At least 1 uppercase").
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- validator → bool Function(String password)
-
Function to check if the password meets this requirement.
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
-
validate(
String password) → bool -
Returns whether
passwordsatisfies this requirement.override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited