CodeNestValidators class

Constructors

CodeNestValidators()

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

age(String? value, {int min = 1, int max = 120, String? errorMsg}) String?
🎂 Age Validator (must be number and within range)
date(String? value, {String errorMsg = 'Enter a valid date (yyyy-mm-dd)'}) String?
📅 Date Validator (yyyy-mm-dd)
email(String? value, {String errorMsg = 'Enter a valid email'}) String?
✅ Email Validator
number(String? value, {String errorMsg = 'Enter a valid number'}) String?
2️⃣ Number validator
password(String? value, {int minLength = 6, bool requireSpecialChar = true, String errorMsg = 'Enter a valid password'}) String?
🔒 Password Validator with minLength, special char, etc.
phone(String? value, {String errorMsg = 'Enter a valid phone number'}) String?
📞Phone Number Validator (IN)
pin(String? value, {int length = 6, String? errorMsg}) String?
3️⃣ OTP PIN Number Validator
required(String? value, {String fieldName = 'This field'}) String?
🆓 Non-empty field validator
time(String? value, {String errorMsg = 'Enter a valid time (HH:mm)'}) String?
⏰ Time Validator (HH:mm)
url(String? value, {String errorMsg = 'Enter a valid URL'}) String?
🌎Url Validator
username(String? value, {String errorMsg = 'Enter a valid username'}) String?
🧍 Username Validator