enumPref

inline fun <T : Enum<*>> SettingsModel.enumPref(default: T, key: String? = null, cache: Boolean = storage.cache): StorageSetting<T>

Delegate enum property

Parameters

default

default enum value

key

custom storage key

cache

enable caching for blocking reads (only used if storage has caching enabled as well)