AmplifySecureStorage class

The default Secure Storage implementation used in Amplify packages.

Inheritance

Constructors

AmplifySecureStorage({required AmplifySecureStorageConfig config})
Generates a AmplifySecureStorage from a config.

Properties

config AmplifySecureStorageConfig
Configuration options for Secure Storage.
finalinherited
hashCode int
The hash code for this object.
no setterinherited
logger → AWSLogger
The logger for this class.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
runtimeTypeName String
The string value of runtimeType, saving a runtime lookup and preventing obfuscation during web compilation.
no setterinherited

Methods

delete({required String key}) Future<void>
Remove a key/value pair from storage.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
read({required String key}) Future<String?>
Read the value of a given key.
override
removeAll() Future<void>
Removes all key-value pairs for the current scope.
override
toString() String
A string representation of this object.
inherited
write({required String key, required String value}) Future<void>
Write a key-value pair to storage.
override

Operators

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

Static Methods

factoryFrom({WebSecureStorageOptions? webOptions, WindowsSecureStorageOptions? windowsOptions, LinuxSecureStorageOptions? linuxOptions, MacOSSecureStorageOptions? macOSOptions, IOSSecureStorageOptions? iOSOptions}) AmplifySecureStorage Function(AmplifySecureStorageScope amplifyScope)
Returns a factory for creating AmplifySecureStorage instances.

Constants

scopeStoragePrefix → const String
A namespace for storing the list of registered scopes.