KeyValueStorage class Null safety

A class to provide helper methods for key value storage using get_storage

This class stores all key value pairs in the keyValueStorageNamespace container

Implementers

Constructors

KeyValueStorage([String namespace = keyValueStorageNamespace])

Properties

box GetStorage
A box to store key value pairs
read / write
hashCode int
The hash code for this object. [...]
read-only, inherited
namespace String
The container to save key value pairs in
final
ready Future<bool>
Is the storage initialized
read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

clear() Future<void>
WARNING! Clears all values from storage namespace
get<T>(String key) Future<T?>
Get the value for a key from storage namespace
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
remove(String key) Future<void>
Remove a key value pair from storage namespace
set(String key, dynamic value) Future<void>
Add a key value pair to storage namespace
toString() String
A string representation of this object. [...]
inherited

Operators

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