DiscoveryRepository

Stored Local Mesh Discovery sessions, their per-preset results, and the nodes heard under each preset.

Functions

Link copied to clipboard
abstract suspend fun deleteSession(sessionId: Long)

Deletes the session together with its preset results and their nodes.

Link copied to clipboard

Every session, newest first.

Link copied to clipboard
abstract suspend fun getNodesByPresetResult(presetResultIds: List<Long>): Map<Long, List<DiscoveredNodeEntity>>

The nodes discovered under each of presetResultIds, keyed by preset result id in the order given.

Link copied to clipboard
abstract suspend fun getPresetResults(sessionId: Long): List<DiscoveryPresetResultEntity>
Link copied to clipboard
Link copied to clipboard
abstract suspend fun getSession(sessionId: Long): DiscoverySessionEntity?
Link copied to clipboard
abstract fun getSessionFlow(sessionId: Long): Flow<DiscoverySessionEntity?>
Link copied to clipboard
abstract suspend fun markInterruptedSessions()

Marks every session still in progress as interrupted, for scans a process death cut short.

Link copied to clipboard
abstract suspend fun updatePresetResult(result: DiscoveryPresetResultEntity)
Link copied to clipboard
abstract suspend fun updateSession(session: DiscoverySessionEntity)