newHiveLazyVaultStore function
Creates a new HiveLazyVaultStore
path
: The base storage location for this store, the current directory if not providedcodec
: TheStoreCodec
used to convert to/from a Map<String, dynamic>` representation to a binary representationencryptionCipher
: The encryption cyphercrashRecovery
: If it supports crash recovery
Implementation
Future<HiveLazyVaultStore> newHiveLazyVaultStore(
{String? path,
StoreCodec? codec,
HiveCipher? encryptionCipher,
bool? crashRecovery}) {
return HiveLazyAdapter.build(
path: path ?? '.',
encryptionCipher: encryptionCipher,
crashRecovery: crashRecovery)
.then((adapter) => HiveLazyVaultStore(adapter, codec: codec));
}