NonNullAnnotationArguments

Not null accessors for AnnotationArguments.

Theoretically an annotation argument cannot be null, however, because of google/ksp#885 this is not true in a multiplatform context.

Only use this accessor if you are not targeting KMP

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
@JvmName(name = "getEnum")
inline operator fun <T : Enum<T>> get(parameter: KProperty1<A, T>): T
@JvmName(name = "getEnumArray")
inline operator fun <T : Enum<T>> get(parameter: KProperty1<A, Array<out T>>): List<T>?

@JvmName(name = "getNumber")
inline operator fun <T : Number> get(parameter: KProperty1<A, T>): T

Returns the value of parameter as an Number.

operator fun get(parameter: KProperty1<A, Annotation>): KSAnnotation

Returns the value of parameter as an KSAnnotation.

@JvmName(name = "getNumberArray")
inline operator fun <T : Number> get(parameter: KProperty1<A, Array<out T>>): List<T>

Returns the value of parameter as a NumbersNumber.

@JvmName(name = "getAnnotationArray")
operator fun get(parameter: KProperty1<A, Array<out Annotation>>): List<KSAnnotation>

Returns the value of parameter as a List of KSAnnotations.

@JvmName(name = "getBooleanArray")
operator fun get(parameter: KProperty1<A, BooleanArray>): List<Boolean>

Returns the value of parameter as a BooleansBoolean.

@JvmName(name = "getStringArray")
operator fun get(parameter: KProperty1<A, Array<out String>>): List<String>

Returns the value of parameter as a StringsString.

@JvmName(name = "getKClassArray")
operator fun get(parameter: KProperty1<A, Array<out KClass<*>>>): List<KSType>

Returns the value of parameter as a KClassesKClass.

@JvmName(name = "getBoolean")
operator fun get(parameter: KProperty1<A, Boolean>): Boolean

Returns the value of parameter as an Boolean.

@JvmName(name = "getString")
operator fun get(parameter: KProperty1<A, String>): String

Returns the value of parameter as an String.

@JvmName(name = "getKClass")
operator fun get(parameter: KProperty1<A, KClass<*>>): KSType

Returns the value of parameter as an KClass.

Link copied to clipboard
fun isDefault(parameter: KProperty1<A, Any>): Boolean

Checks whether the parameter uses its default value.