Skip to content

KaBuiltinTypes

KaType instances for built-in types.

Inheritors

Properties

annotationType

abstract val annotationType: KaType

The Annotation type.

any

abstract val any: KaType

The Any class type.

boolean

abstract val boolean: KaType

The Boolean class type.

byte

abstract val byte: KaType

The Byte class type.

char

abstract val char: KaType

The Char class type.

double

abstract val double: KaType

The Double class type.

float

abstract val float: KaType

The Float class type.

int

abstract val int: KaType

The Int class type.

long

abstract val long: KaType

The Long class type.

nothing

abstract val nothing: KaType

The Nothing class type.

nullableAny

abstract val nullableAny: KaType

The Any? type.

nullableNothing

abstract val nullableNothing: KaType

The Nothing? type.

short

abstract val short: KaType

The Short class type.

string

abstract val string: KaType

The String class type.

throwable

abstract val throwable: KaType

The Throwable class type.

token

abstract val token: KaLifetimeToken

The KaLifetimeToken which determines the lifetime of the lifetime owner.

unit

abstract val unit: KaType

The Unit class type.

Functions

assertIsValidAndAccessible

isValid

Whether the lifetime owner is still valid, i.e. we are still in the scope of the lifetime owner's regular lifetime.

withValidityAssertion

inline fun <R> KaLifetimeOwner.withValidityAssertion(action: () -> R): R

Executes action only if the KaLifetimeOwner is still valid and accessible. Otherwise, throws a validity exception based on the concrete violation.