getValue

suspend fun <T> getValue(key: Preferences.Key<T>, defaultValue: T): T

Get a preference value

Parameters

key

: The key of the preference

defaultValue

: The default value of the preference