Looking specifically at the Patterns example given, it may be desirable for an implementation to attempt to optimize the validation of a list of patterns or tokens.
It should be specified that annotations specifying a ConstraintValidator have the constraint validator take precedence over the scanning of an annotation "value" for an array of constraint annotations. This way a @Patterns annotation, with appropriate constraint validator, could be built to optimize the matching of a set of patterns and be treated as a single validator.
|