1. @Data
    2. @Accessors(chain = true)
    3. public class RegexEntity {
    4. @Matcher(regex = "^\\d+$")
    5. private String regexValid;
    6. @Matcher(regex = "^\\d+$", accept = false)
    7. private String regexInValid;
    8. }