SharedPreferencesAdapter class

Implemented types

Constructors

SharedPreferencesAdapter({String? boxName, bool enableEncryption = false, String? encryptionKey})

Properties

boxName String?
final
enableEncryption bool
Indicates if encryption is enabled for this adapter.
final
hashCode int
The hash code for this object.
no setterinherited
prefs Future<SharedPreferences>
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

clear() Future<void>
Clears all data from the cache.
override
containsKey(String key) Future<bool>
Checks if the cache contains a value associated with the given key.
override
containsKeys(List<String> keys) Future<Map<String, bool>>
Checks if the cache contains values associated with all the given keys.
override
delete(String key) Future<void>
Deletes the value associated with the given key.
override
deleteAll(List<String> keys) Future<void>
Deletes multiple values associated with the given keys.
override
get(String key) Future<CacheItem?>
Retrieves the CacheItem associated with the given key.
override
getAll(List<String> keys) Future<Map<String, CacheItem>>
Retrieves multiple CacheItems associated with the given keys.
override
getKeys({int? limit, int? offset}) Future<List<String>>
Returns a list of all keys in the cache.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
put(String key, CacheItem item) Future<void>
Stores a value in the cache with the given key.
override
putAll(Map<String, CacheItem> entries) Future<void>
Stores multiple values in the cache with the given keys.
override
toString() String
A string representation of this object.
inherited

Operators

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