Interface HibernateConstraintViolationBuilder

    • Method Detail

      • enableExpressionLanguage

        @Incubating
        default HibernateConstraintViolationBuilder enableExpressionLanguage()
        Enable Expression Language with the default Expression Language feature level for the constraint violation created by this builder if the chosen MessageInterpolator supports it.

        If you enable this, you need to make sure your message template does not contain any unescaped user input (such as the validated value): use addExpressionVariable() to inject properly escaped variables into the template.

        Since:
        6.2
      • enableExpressionLanguage

        @Incubating
        HibernateConstraintViolationBuilder enableExpressionLanguage​(ExpressionLanguageFeatureLevel level)
        Enable Expression Language for the constraint violation created by this builder if the chosen MessageInterpolator supports it.

        If you enable this, you need to make sure your message template does not contain any unescaped user input (such as the validated value): use addExpressionVariable() to inject properly escaped variables into the template.

        Parameters:
        level - The Expression Language features level supported.
        Since:
        6.2