SodiumHiveLocalStorage class

A customization of HiveLocalStorage that uses SodiumHiveCipher instead of HiveAesCipher for local encryption.

Unlike the normal HiveLocalStorage this class always requires an encryption key, as it does not make sense without one. Internally, a fake implementation of a HiveAesCipher that wraps SodiumHiveCipher is used, to not break the API of the base class.

Constructors

SodiumHiveLocalStorage({required HiveInterface hive, required Sodium sodium, required SecureKey encryptionKey, FutureOr<String> baseDirFn()?, bool? clear})
Constructor.

Properties

baseDirFn → (FutureOr<String> Function()?)
finalinherited
clear → LocalStorageClearStrategy
finalinherited
encryptionCipher → HiveAesCipher
no setter
hashCode int
The hash code for this object.
no setterinherited
hive → HiveInterface
finalinherited
isInitialized bool
getter/setter pairinherited
path String
latefinalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sodiumHiveCipher SodiumHiveCipher
The internally used SodiumHiveCipher instance.
no setter

Methods

deleteBox(String name) Future<void>
inherited
destroy() Future<void>
inherited
initialize() Future<void>
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
openBox<B>(String name, {bool retry = true}) Future<Box<B>>
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited