MyAnnotType.java 685 B

12345678910111213141516171819202122
  1. import java.lang.annotation.*;
  2. import static java.lang.annotation.ElementType.*;
  3. @Documented
  4. @Retention(RetentionPolicy.RUNTIME)
  5. @Target(value={CONSTRUCTOR, FIELD, LOCAL_VARIABLE, METHOD, PACKAGE, PARAMETER, TYPE})
  6. public @interface MyAnnotType {
  7. byte bvalue() default 1;
  8. short svalue() default 2;
  9. int ivalue() default 3;
  10. long lvalue() default 4;
  11. float fvalue() default 1.5f;
  12. double dvalue() default 2.5;
  13. boolean blvalue() default true;
  14. char chvalue() default 'X';
  15. String name() default "()";
  16. Class clvalue() default java.io.File.class;
  17. String[] names();
  18. ElementType etype() default ElementType.PACKAGE;
  19. ElementType[] etypes() default ElementType.PACKAGE;
  20. }