Class PatternValidatorForI18nString

java.lang.Object
dev.orne.i18n.validation.AbstractValidatorForI18nString<javax.validation.constraints.Pattern>
dev.orne.i18n.validation.PatternValidatorForI18nString
All Implemented Interfaces:
javax.validation.ConstraintValidator<javax.validation.constraints.Pattern,I18nString>

@API(status=INTERNAL, since="0.1") public class PatternValidatorForI18nString extends AbstractValidatorForI18nString<javax.validation.constraints.Pattern>
Implementation of Javax Bean Validation ConstraintValidator for Pattern constraint on I18nString instances.
Since:
0.1
Version:
1.0, 2021-02
Author:
(w) Iker Hernaez
See Also:
  • Constructor Details

    • PatternValidatorForI18nString

      public PatternValidatorForI18nString()
      Creates a new instance.
  • Method Details

    • initialize

      public void initialize(@NotNull @NotNull javax.validation.constraints.Pattern parameters)
    • isTextValid

      protected boolean isTextValid(@NotNull @NotNull String text)
      Validates if the text is valid.
      Specified by:
      isTextValid in class AbstractValidatorForI18nString<javax.validation.constraints.Pattern>
      Parameters:
      text - The text to validate
      Returns:
      If the text is valid