ReplayEngine

class ReplayEngine(scope: CoroutineScope, eventSource: ScreenEventSource = ScreenEventSource { emptyFlow() }) : DefaultLifecycleObserver

Process-lifecycle-aware replay ring-buffer collector (AND-LIFE-03, D-16).

Subscribes to a screen-event source and populates a bounded ring buffer used for replay-on-feedback. Collection runs only while the app is foregrounded — the ring buffer is paused on background to avoid wasted CPU and to keep the replay window meaningful.

Threat mitigations:

  • T-33-13: listenJob is cancelled in onStop; no leaked collectors.

Constructors

Link copied to clipboard
constructor(scope: CoroutineScope, eventSource: ScreenEventSource = ScreenEventSource { emptyFlow() })

Properties

Link copied to clipboard

Functions

Link copied to clipboard
open override fun onStart(owner: LifecycleOwner)
Link copied to clipboard
open override fun onStop(owner: LifecycleOwner)