Repo created
This commit is contained in:
parent
324070df30
commit
2d33a757bf
644 changed files with 99721 additions and 2 deletions
22
app/src/main/kotlin/at/bitfire/davdroid/db/SyncStatsDao.kt
Normal file
22
app/src/main/kotlin/at/bitfire/davdroid/db/SyncStatsDao.kt
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
/*
|
||||
* Copyright © All Contributors. See LICENSE and AUTHORS in the root directory for details.
|
||||
*/
|
||||
|
||||
package at.bitfire.davdroid.db
|
||||
|
||||
import androidx.room.Dao
|
||||
import androidx.room.Insert
|
||||
import androidx.room.OnConflictStrategy
|
||||
import androidx.room.Query
|
||||
import kotlinx.coroutines.flow.Flow
|
||||
|
||||
@Dao
|
||||
interface SyncStatsDao {
|
||||
|
||||
@Insert(onConflict = OnConflictStrategy.REPLACE)
|
||||
suspend fun insertOrReplace(syncStats: SyncStats)
|
||||
|
||||
@Query("SELECT * FROM syncstats WHERE collectionId=:id")
|
||||
fun getByCollectionIdFlow(id: Long): Flow<List<SyncStats>>
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue