1. /*
  2. * @(#)Retention.java 1.5 04/06/22
  3. *
  4. * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
  5. * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  6. */
  7. package java.lang.annotation;
  8. /**
  9. * Indicates how long annotations with the annotated type are to
  10. * be retained. If no Retention annotation is present on
  11. * an annotation type declaration, the retention policy defaults to
  12. * <tt>RetentionPolicy.CLASS</tt>.
  13. *
  14. * <p>A Target meta-annotation has effect only if the meta-annotated
  15. * type is use directly for annotation. It has no effect if the meta-annotated
  16. * type is used as a member type in another annotation type.
  17. *
  18. * @author Joshua Bloch
  19. * @since 1.5
  20. */
  21. @Documented
  22. @Retention(RetentionPolicy.RUNTIME)
  23. @Target(ElementType.ANNOTATION_TYPE)
  24. public @interface Retention {
  25. RetentionPolicy value();
  26. }