Mark Woon, in case you still remember, what is your use case for this (yeah, I know it has been a ridiculously long delay ? And by "overriding", do you mean "disabling" essentially? My stance so far is that the demand for this indicates some sort of modelling issue (thinking of Liskov Substitution Principle here), but I'm happy to be proven otherwise. What I possibly could see us doing is to add a @IgnoreInheritedConstrains annotation (as discussed in the context of
BVAL-256 Open ). An alternative would be some sort of SPI which allows to filter the constraints to be applied, but that seems much more complex (implementation and usage-wise), so a simple annotation may be enough. When giving it at the class level it needs to be decided whether this only applies to class-level constraints or all constraints. |