Reference

data class Reference<out T : Any>(val current: T, val next: () -> T?)

A reference gives a data and a function to later check the validity and retrieve that data.

Parameters

current

The value of the reference at the time of reference creation.

next

A function that returns the value of the reference, or null if the reference has become invalid, when later needed.

Constructors

Link copied to clipboard
constructor(current: T, next: () -> T?)

Properties

Link copied to clipboard
val current: T
Link copied to clipboard
val next: () -> T?