createEncryptedPreferencesDataStore

fun createEncryptedPreferencesDataStore(storage: Storage<Preferences>, migrations: List<DataMigration<Preferences>> = emptyList(), corruptionHandler: ReplaceFileCorruptionHandler<Preferences>? = null, registry: StoreRegistry? = null): DataStore<Preferences>

Encrypted Preferences DataStore over caller-supplied storage.

Ensure io.github.jdbenitez94.criollo.kmp.foundation.kryptostore.crypto.CryptoRuntime is Ready before use (REQ-STO-05).


fun createEncryptedPreferencesDataStore(cipher: Cipher, producePath: () -> Path, options: EncryptedStoreOptions = EncryptedStoreOptions(), migrations: List<DataMigration<Preferences>> = emptyList(), corruptionHandler: ReplaceFileCorruptionHandler<Preferences>? = null, registry: StoreRegistry? = null): DataStore<Preferences>

File-backed encrypted Preferences DataStore (Okio). Path must end with .preferences_pb.