JvmSuppressWildcards
@Target
(
[AnnotationTarget.CLASS, AnnotationTarget.FUNCTION, AnnotationTarget.PROPERTY, AnnotationTarget.TYPE]
)
annotation
class
JvmSuppressWildcards
(Common source) (JVM source)
Instructs compiler to generate or omit wildcards for type arguments corresponding to parameters with
declaration-site variance, for example such as
Collection<out T>
has.
If the innermost applied
@JvmSuppressWildcards
has
suppress=true
, the type is generated without wildcards.
If the innermost applied
@JvmSuppressWildcards
has
suppress=false
, the type is generated with wildcards.
It may be helpful only if declaration seems to be inconvenient to use from Java.
Constructors
<init>
Instructs compiler to generate or omit wildcards for type arguments corresponding to parameters with
declaration-site variance, for example such as
Collection<out T>
has.
<init>
(
suppress
:
Boolean
=
true
)
Properties
suppress
val
suppress
:
Boolean
Extension Properties
annotationClass
Returns a KClass instance corresponding to the annotation type of this annotation.
val
<
T
:
Annotation
>
T
.
annotationClass
:
KClass
<
out
T
>