Retention
@Target
(
[AnnotationTarget.ANNOTATION_CLASS]
)
annotation
class
Retention
(Common source) (Native source)
This meta-annotation determines whether an annotation is stored in binary output and visible for reflection. By default, both are true.
Constructors
<init>
This meta-annotation determines whether an annotation is stored in binary output and visible for reflection. By default, both are true.
<init>
(
value
:
AnnotationRetention
=
AnnotationRetention.RUNTIME
)
Properties
value
necessary annotation retention (RUNTIME, BINARY or SOURCE)
val
value
:
AnnotationRetention
Extension Properties
annotationClass
Returns a KClass instance corresponding to the annotation type of this annotation.
val
<
T
:
Annotation
>
T
.
annotationClass
:
KClass
<
out
T
>