|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | ||||||||
@Target(value={METHOD,FIELD})
@Retention(value=RUNTIME)
@Documented
@Inherited
public @interface JvGroupGroup annotation which specifies 1 or more groups and also automatically assures the method is validated. Specify on getXXX() methods. Thus a method *must* have this annotation if it requires validation (whatever that may be)
Maximum 1 annotation per method (same method in parent class can have 1 too).
| Optional Element Summary | |
|---|---|
java.lang.String[] |
disableRecursionForGroups
You can disable recursion for a method by specifying which validation group(s) must NOT recurse, in other words: The validator will not recurse (thus validate the methods' return value) for the group in this array. |
boolean |
exposeInSubClass
If set to true, it means that if a class specifies a JvGroup on one of its methods, its subclasses that override such method will be validated automatically too. |
java.lang.String[] |
groups
Name of group, defaults to a group called 1. |
public abstract java.lang.String[] groups
Defaults to JvGroup.DEFAULT_GROUP (1).
public abstract java.lang.String[] disableRecursionForGroups
Use GROUP_APPLY_ALL of this annotation to disable any recursion for this method for all validation groups.
Note: If a group is specified in an inheritance relationship the most specialized class's groups disableRecursionForGroups() is taken. Assume: B extends A, on A you have a method with JvGroup telling recursion for group 1 is disabled, in B you have the same method telling recursion is allowed -> recursion is allowed then if you validate an instance of B. When you validate an instance of A, recursion is disabled for group 1, as A is now the 'highest' object.
Defaults to empty array (thus nothing is disabled).
public abstract boolean exposeInSubClass
Defaults to false.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | ||||||||