|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | ||||||||
@Documented @Retention(value=RUNTIME) @Target(value=ANNOTATION_TYPE) public @interface SubtypeOf
A meta-annotation to specify all the qualifiers that the given qualifier
is a subtype of. This provides a declarative way to specify the type
qualifier hierarchy. (Alternatively, the hierarchy can be defined
procedurally by subclassing QualifierHierarchy or
TypeHierarchy.)
Example:
@SubtypeOf( { Nullable.class } )
public @interface NonNull { }
If a qualified type is a subtype of the same type without any qualifier,
then use Unqualified.class in place of a type qualifier
class. For example, to express that @Encrypted C
is a subtype of C (for every class
C), and likewise for @Interned, write:
@SubtypeOf(Unqualified.class)
public @interface Encrypted { }
| Required Element Summary | |
|---|---|
Class<? extends Annotation>[] |
value
An array of the supertype qualifiers of the annotated qualifier |
| Element Detail |
|---|
public abstract Class<? extends Annotation>[] value
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT | ||||||||