Optional

class Optional<in M, T>(initializer: M.() -> T?) : Delegate<M, T>

Delegate for optional (nullable) values.

Constructors

Link copied to clipboard
constructor(initializer: M.() -> T?)

Properties

Link copied to clipboard
var value: T?

Functions

Link copied to clipboard
operator fun getValue(thisRef: Any?, property: KProperty<*>): T?

Delegate for value reads.

Link copied to clipboard
fun initialize(module: M)

Initializes value from the injection module.

Link copied to clipboard
operator fun setValue(thisRef: Any?, property: KProperty<*>, t: T?)

Delegate for value writes.