SnapshotManager class

Manages persist/restore of AppSnapshot via SharedPreferences.

Crash Loop Detection

Tracks how many times the app has launched within a short window. If the app crashes 3+ times within 60 seconds, isInCrashLoop returns true, signaling that the recovery UI should bypass all Flutter widgets and show a minimal platform-native fallback.

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

isInCrashLoop() Future<bool>
Checks if the app is in a crash loop (3+ crashes within 60 seconds).
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
record(AppSnapshot snapshot) Future<void>
Save an AppSnapshot to persistent storage.
resetCrashCount() Future<void>
Resets the crash counter. Call after a successful app launch (i.e. the user interacted without crashing).
restore() Future<AppSnapshot?>
Restore the last saved snapshot.
toString() String
A string representation of this object.
inherited
wipe() Future<void>
Wipe the stored snapshot. Called on corrupt data or user "Start Fresh".

Operators

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

Static Properties

instance SnapshotManager
The singleton instance.
final