RetainedCaptureQuery

class RetainedCaptureQuery(store: () -> EventStore?, currentSessionId: () -> String?)

Session selection and durable capture reads shared by inspector surfaces.

Constructors

Link copied to clipboard
constructor(store: () -> EventStore?, currentSessionId: () -> String?)

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
suspend fun events(sessionId: String? = null, limit: Int = DEFAULT_LIMIT, pluginIds: Set<String> = emptySet()): List<StoredEvent>

pluginIds empty (the default) preserves this method's original contract exactly: an explicit sessionId wins, otherwise it falls back to whatever session is current right now. That fallback is correct for a live read (e.g. the Android in-app inspector's own Crashes tab, always asking about the run it is embedded in) but wrong for a developer asking "show me every crash" after the process that hit one has already died and a new session is current -- so a non-empty pluginIds with no explicit sessionId instead reads across every retained session via EventStore.recentEventsForPlugins, ignoring currentSessionId entirely.

Link copied to clipboard
suspend fun eventsForExport(sessionId: String? = null): List<StoredEvent>

Full-session reads are reserved for explicitly bounded export generation.