CacheStore class abstract interface

Backing store contract (BLUEPRINT_V2 §7.7). Values must be JSON-serializable for the file/database stores.

Implementers

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scope → StateScope
no setter

Methods

acquireLock(String name, String owner, Duration ttl) → Future<bool>
add(String key, Object? value, {Duration? ttl}) → Future<bool>
Stores only when key is absent (atomic per store scope).
decrement(String key, [int by = 1]) → Future<int>
flush() → Future<void>
forceReleaseLock(String name) → Future<void>
forever(String key, Object? value) → Future<void>
forget(String key) → Future<bool>
get(String key) → Future<Object?>
increment(String key, [int by = 1]) → Future<int>
lockOwner(String name) → Future<String?>
many(List<String> keys) → Future<Map<String, Object?>>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
put(String key, Object? value, {Duration? ttl}) → Future<void>
Stores value for ttl (null = forever).
putMany(Map<String, Object?> values, {Duration? ttl}) → Future<void>
releaseLock(String name, String owner) → Future<bool>
toString() → String
A string representation of this object.
inherited

Operators

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