CachedValue

Caches a value in memory with an expiration.

Parameters

<T>

Constructors

Link copied to clipboard
constructor()
constructor(@NonNull clock: Clock)

Functions

Link copied to clipboard
open fun expire()
Link copied to clipboard
open fun expireIf(predicate: Predicate<T>)
Link copied to clipboard
open fun get(): T
Link copied to clipboard
Link copied to clipboard
open fun set(@Nullable value: T, expiryDateMs: Long)