XCrash class

Pull persisted native crash records and re-emit them as Log.f. Call once during app boot, after Log.configure(...), before runApp.

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
toString() → String
A string representation of this object.
inherited

Operators

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

Static Methods

drainAndReport({MethodChannel? channel}) → Future<void>
Drains persisted native crashes from prior runs and re-emits each through Log.f. Each record is acked back to the plugin after successful re-emit so the underlying file is deleted. Errors talking to the channel are swallowed — crash drain must never block app start.
triggerNativeTestCrash({MethodChannel? channel}) → Future<void>
Asks the native plugin to raise an uncaught exception, crashing the app. On the next launch, drainAndReport should pick the record up. Intended for end-to-end testing of the crash pipeline; do not ship buttons that call this in release builds.