1 package checkers.quals; 2 3 import java.lang.annotation.Documented; 4 import static java.lang.annotation.ElementType.*; 5 import java.lang.annotation.Retention; 6 import java.lang.annotation.RetentionPolicy; 7 import java.lang.annotation.Target; 8 9 /** 10 * Specifies the annotations to be included in a type without having to provide 11 * them explicitly. 12 * 13 * This annotation permits specifying multiple default qualifiers for more 14 * than one type system. It is necessary because Java forbids multiple 15 * annotations of the same name at a single location. 16 * 17 * Example: 18 * <!-- is a hack that prevents @ from being the first charater on the line, which confuses Javadoc --> 19 * <code><pre> 20 * @DefaultQualifiers({ 21 * @DefaultQualifier("NonNull"), 22 * @DefaultQualifier(value = "Interned", locations = ALL_EXCEPT_LOCALS), 23 * @DefaultQualifier("Tainted") 24 * }) 25 * </pre></code> 26 * 27 * @see DefaultQualifier 28 */ 29 @Documented 30 @Retention(RetentionPolicy.RUNTIME) 31 @Target({CONSTRUCTOR, METHOD, FIELD, LOCAL_VARIABLE, PARAMETER, TYPE}) 32 public @interface DefaultQualifiers { 33 /** The default qualifier settings */ 34 DefaultQualifier[] value() default { }; 35 } 36