Hi Gunnar, Well, I think it is not worth to implement implementing the feature if it raises no portability. The other solution to the problem is just to create custom composite constraint annotations annotation based on standard ones. As an example: {code} <bean class="com.my.User" ignore-annotations="true"> <field name="email"> <constraint annotation="com.my.constraint.EmailPattern"/> </field> ..... </bean> {code}
and the EmailPattern
{code} @Pattern(Regxeps) @Target( { METHOD, FIELD, ANNOTATION_TYPE }) @Retention(RUNTIME) @Constraint(validatedBy = {}) @Documented public @interface EmailPattern {
String message() default "someMessageKey"; Class<?>[] groups() default {}; Class<? extends Payload>[] payload() default {}; } {code}
|