All Downloads are FREE. Search and download functionalities are using the official Maven repository.

main.com.sceyt.chatuikit.persistence.dao.PendingMarkerDao.kt Maven / Gradle / Ivy

There is a newer version: 1.7.2
Show newest version
package com.sceyt.chatuikit.persistence.dao

import androidx.room.Dao
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import com.sceyt.chatuikit.persistence.entity.pendings.PendingMarkerEntity

@Dao
interface PendingMarkerDao {

    @Insert(onConflict = OnConflictStrategy.IGNORE)
    suspend fun insert(entity: PendingMarkerEntity)

    @Insert(onConflict = OnConflictStrategy.IGNORE)
    suspend fun insertMany(entities: List)

    @Query("select * from PendingMarker")
    suspend fun getAllMarkers(): List

    @Query("delete from PendingMarker where messageId =:messageId and name =:status")
    suspend fun deleteMessageMarkerByStatus(messageId: Long, status: String)

    @Query("delete from PendingMarker where messageId in (:messageIds) and name =:status")
    suspend fun deleteMessagesMarkersByStatus(messageIds: List, status: String)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy