match static method
FormFieldValidator that requires the field's value to match the provided regex pattern.
Parameters:
regexThe regex pattern to match.errorTextThe error message when the value does not match the pattern.checkNullOrEmptyWhether to check for null or empty values.
Implementation
static FormFieldValidator<String> match(
RegExp regex, {
String? errorText,
bool checkNullOrEmpty = true,
}) => MatchValidator(
regex,
errorText: errorText,
checkNullOrEmpty: checkNullOrEmpty,
).validate;