Synchronous key/value backend used by BootAudit to persist its trail across app boots.
Implementations must be synchronous so BootAudit.log can run from the
very first line of main() without awaiting a future. The contract is
deliberately minimal — JSON-encoded strings in, JSON-encoded strings out.
Bundled implementations:
- InMemoryBootAuditStorage — process-local, lost on restart. Useful for tests and non-web platforms where persistence isn't wired yet.
- LocalStorageBootAuditStorage — browser
localStorageon web, no-op on non-web (selected at compile time viadart.library.js_interop).
To plug in a different backend (e.g. SharedPreferences, a file on
disk, IndexedDB), implement this interface and pass an instance to the
BootAudit constructor.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
read(
String key) → String? -
Returns the value stored under
key, ornullif absent or unreadable. -
remove(
String key) → void -
Removes any value stored under
key. No-op if absent. -
toString(
) → String -
A string representation of this object.
inherited
-
write(
String key, String value) → void -
Persists
valueunderkey, overwriting any previous value.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited