pub enum StringSpecialCharLocale {
MustHaveSpecialChars,
MustHaveUppercaseAndLowercase,
MustHaveUppercase,
MustHaveLowercase,
MustHaveDigit,
}Expand description
An enumeration defining various string constraints or requirements based on the presence of special characters, case sensitivity, or digits.
This enum can be used to specify which kind of validation or rules should be applied to a string across different locales, ensuring compliance with specific character requirements.
§Variants
-
MustHaveSpecialCharsEnforces that the string must contain at least one special character (e.g., symbols like@,#,$, etc.). -
MustHaveUppercaseAndLowercaseEnforces that the string must contain at least one uppercase and one lowercase character. -
MustHaveUppercaseEnforces that the string must contain at least one uppercase character. -
MustHaveLowercaseEnforces that the string must contain at least one lowercase character. -
MustHaveDigitEnforces that the string must contain at least one numeric digit (0-9).