java.lang.annotation
Annotation Type Retention


@Documented
@Retention(value sample code for java.lang.annotation.Retention.value() definition code for java.lang.annotation.Retention.value() =RUNTIME sample code for java.lang.annotation.RetentionPolicy.RUNTIME definition code for java.lang.annotation.RetentionPolicy.RUNTIME )
@Target(value sample code for java.lang.annotation.Target.value() definition code for java.lang.annotation.Target.value() =ANNOTATION_TYPE sample code for java.lang.annotation.ElementType.ANNOTATION_TYPE definition code for java.lang.annotation.ElementType.ANNOTATION_TYPE )
public @interface Retention

Indicates how long annotations with the annotated type are to be retained. If no Retention annotation is present on an annotation type declaration, the retention policy defaults to RetentionPolicy.CLASS.

A Target meta-annotation has effect only if the meta-annotated type is use directly for annotation. It has no effect if the meta-annotated type is used as a member type in another annotation type.

Since:
1.5

Required Element Summary
 RetentionPolicy sample code for java.lang.annotation.RetentionPolicy definition code for java.lang.annotation.RetentionPolicy value sample code for java.lang.annotation.Retention.value() definition code for java.lang.annotation.Retention.value()
           
 

Element Detail

value

public abstract RetentionPolicy sample code for java.lang.annotation.RetentionPolicy definition code for java.lang.annotation.RetentionPolicy  value