validart library

Classes

AfterValidator
A validator that checks if a given DateTime is after a specific date.
AlphanumericValidator
A validator that checks whether a given string is alphanumeric.
AlphaValidator
A validator that checks whether a given string contains only letters.
AnyValidator<T>
A validator that checks if a value satisfies at least one of the given types.
ArrayMessage
A message container for validation errors related to array (list) values.
BaseMessage
A base class for validation messages used in the Validart validation library.
BeforeValidator
A validator that checks if a given DateTime is before a specific date.
BetweenDatesValidator
A validator that checks if a given DateTime falls within a specified date range.
BetweenValidator<T extends num>
A validator that ensures a given num value falls within a specified range.
BoolMessage
A message class for boolean (true/false) validation errors.
CardValidator
A validator that checks whether a given string is a valid credit or debit card number.
CEPValidator
A validator that ensures a given string is a valid Brazilian postal code (CEP).
CNPJValidator
A validator that ensures a given string is a valid Brazilian CNPJ.
ContainsArrayValidator<T>
A validator that checks if a list contains all required elements.
ContainsValidator
A validator that checks whether a given string contains a specific substring.
CPFValidator
A validator that checks whether a given string is a valid Brazilian CPF number.
DateMessage
A message container for validation errors related to date values.
DateValidator
A validator that checks whether a given string represents a valid date.
DecimalValidator
A validator that ensures a given double value is a decimal (non-integer).
DoubleMessage
A message class for validation errors related to double values.
DoubleStringValidator
A validator that checks whether a given string represents a valid double value.
EmailValidator
A validator that checks whether a given string is a valid email address.
EndsWithValidator
A validator that checks whether a given string ends with a specific suffix.
EqualsValidator
A validator that checks whether a given string is exactly equal to a specified value.
EvenValidator
A validator that ensures a given int value is even.
EveryValidator<T>
A validator that ensures a value satisfies all the given types.
FiniteValidator
A validator that ensures a given double value is finite (not infinite or NaN).
IntegerStringValidator
A validator that checks whether a given string represents a valid integer value.
IntegerValidator
A validator that ensures a given double value is an integer.
IntMessage
A message class for validation errors related to int values.
IPValidator
A validator that checks whether a string is a valid IPv4 or IPv6 address.
IsFalseValidator
A validator that checks if a boolean value is false.
IsTrueValidator
A validator that checks if a boolean value is true.
JwtValidator
A validator that checks whether a given string is a valid JWT (JSON Web Token).
MapMessage
A message class for validation errors related to Map<String, dynamic> values.
MaxLengthValidator<T>
A validator that ensures a string or list does not exceed a specified maximum length.
MaxValidator<T extends num>
A validator that ensures a given num value does not exceed a specified maximum limit.
Message
A container for all validation messages used within Validart.
MinLengthValidator<T>
A validator that ensures a value has a minimum length.
MinValidator<T extends num>
A validator that ensures a given num value meets a specified minimum limit.
MultipleOfValidator<T extends num>
A validator that ensures a given num value is a multiple of a specified factor.
NegativeValidator<T extends num>
A validator that ensures a given num value is negative.
NumberMessage<T extends num>
A message container for validation errors related to numerical values.
NumMessage
A message container for validation errors related to num values.
OddValidator
A validator that ensures a given int value is odd.
PasswordValidator
A validator that ensures a string meets strong password requirements.
PatternValidator
A validator that checks whether a string matches a specific regular expression pattern.
PhoneValidator
A validator for phone numbers with support for different country and area codes.
PositiveValidator<T extends num>
A validator that ensures a given num value is positive.
PrimeValidator
A validator that checks whether a given integer is a prime number.
RefineMapValidator
A specialized validator for refining validation logic on a map.
RefineValidator<T>
A validator that allows for custom validation logic.
RequiredValidator<T>
A validator that ensures a value is provided.
SlugValidator
A validator that checks whether a given string is a valid slug.
StartsWithValidator
A validator that checks whether a given string starts with a specific prefix.
StringMessage
A message container for validation errors related to string values.
TimeValidator
A validator that checks whether a given string is a valid time format.
UniqueValidator<T>
A validator that checks if all elements in a list are unique.
UrlValidator
A validator that checks whether a given string is a valid URL.
UUIDValidator
A validator that checks whether a given string is a valid UUID of a specified version.
Validart
The Validart class is the entry point for defining validation rules.
Validator<T>
An abstract base class for defining validation logic.
ValidatorWithMessage<T>
An abstract base class for validators that include a predefined error message.
VArray<T>
A validation class for lists (List<T>) in Validart.
VBool
A validator for bool values, providing validation rules for boolean-specific constraints.
VDate
A validation class for DateTime values in Validart.
VDouble
A validator for double values, supporting various constraints.
VInt
A validation class for int values in Validart.
VMap
A validator for Map<String, dynamic> values, enabling object validation.
VNum
A validator for num values, supporting various constraints.
VNumber<T extends num>
A base class for validating numerical values (int, double, and num).
VPrimitive<T>
A validation class that supports any and every conditions.
VRefine<T>
A base class that extends VType<T> and provides custom validation rules.
VString
VString is a validation class for String values in Validart.
VType<T>
VType<T> is an abstract base class for defining validation rules in Validart.
WeekdayValidator
A validator that checks if a given DateTime falls on a weekday (Monday to Friday).
WeekendValidator
A validator that checks if a given DateTime falls on a weekend (Saturday or Sunday).

Enums

AreaCodeFormat
Defines how the area code should be handled in phone number validation.
CaseSensitivity
Defines case sensitivity behavior for string validations.
CountryCodeFormat
Defines the format requirement for country codes in phone number validation.
PhoneType
Represents different phone number formats for various countries, including their required pattern, area code, and country code format.
UUIDVersion
Enum representing different versions of UUID (Universally Unique Identifier). Each version follows a specific structure and is validated using a regex pattern.
ValidationMode
Defines the validation mode for formatted and unformatted values.