-
public final class CacheKt
-
-
Method Summary
Modifier and Type Method Description final static <V extends Any> VgetOrPut(CacheTransaction<V> $self, String key, SuspendFunction0<V> defaultValue)Gets the current cached value for the given key or creates and caches a new one. final static <V extends Any, F extends Any> Try<V, F>getOrTryPut(CacheTransaction<V> $self, String key, SuspendFunction0<Try<V, F>> defaultValue)Gets the current cached value for the given key or creates and caches a new one. -
-
Method Detail
-
getOrPut
final static <V extends Any> V getOrPut(CacheTransaction<V> $self, String key, SuspendFunction0<V> defaultValue)
Gets the current cached value for the given key or creates and caches a new one.
-
getOrTryPut
final static <V extends Any, F extends Any> Try<V, F> getOrTryPut(CacheTransaction<V> $self, String key, SuspendFunction0<Try<V, F>> defaultValue)
Gets the current cached value for the given key or creates and caches a new one.
-
-
-
-