Uploaded image for project: 'Hibernate Validator'
  1. Hibernate Validator
  2. HV-270

Verify in the annotation processor that constraints are not stupid

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 4.0.2.GA
    • Fix Version/s: None
    • Component/s: annotation-processor
    • Labels:
      None
    • Last commented by a user?:
      true

      Description

      For example:

      • @Pattern should have a valid regular exception
      • @Size should have min <= max
        etc

        Attachments

          Issue Links

            Activity

            Hide
            kevinpollet Kevin Pollet added a comment - - edited

            The following checks should be added to the AP:

            • @DecimalMax, @DecimalMin should have a valid BigDecimal representation
            • @Digits should have integer >= 0 and fraction >= 0
            • @Length should have min >= 0, max >= 0 and min <= max
            • @Pattern should have a valid regular expression
            • @Size should have min >=0, max >= 0 and min <= max
            • @ScriptAssert should have script, lang and alias with a length > 0

            Maybe I've forgotten some checks, feel free to complete the list

            Show
            kevinpollet Kevin Pollet added a comment - - edited The following checks should be added to the AP: @DecimalMax, @DecimalMin should have a valid BigDecimal representation @Digits should have integer >= 0 and fraction >= 0 @Length should have min >= 0, max >= 0 and min <= max @Pattern should have a valid regular expression @Size should have min >=0, max >= 0 and min <= max @ScriptAssert should have script, lang and alias with a length > 0 Maybe I've forgotten some checks, feel free to complete the list

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated: