TokenCredentialManager

constructor(client: OAuth2Client, storage: TokenStorage, defaultIdStore: DefaultCredentialIdStore, onStorageError: (Exception) -> Boolean? = null)

Parameters

client

The OAuth2Client used for token operations.

storage

The TokenStorage for persisting tokens.

defaultIdStore

Store for the default credential ID.

onStorageError

Optional callback invoked when a storage operation throws. Return true to retry the failed operation once; return false (or omit) to rethrow. The decision is based on the thrown Exception, for example:

onStorageError = { e -> e is android.database.sqlite.SQLiteException }