package com.isidroid.spot.data.source.local.dao

import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query
import com.isidroid.spot.model.PrintProfile

@Dao
interface PrintProfileDao {
    @Query("SELECT * FROM PrintProfile WHERE id IN (:ids)")
    fun findPrintProfiles(vararg ids: String): List<PrintProfile>

    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun insert(vararg printProfile: PrintProfile)

    @Delete
    fun delete(vararg printProfile: PrintProfile)

    @Query("SELECT * FROM PrintProfile WHERE spotId IN (:ids)")
    fun findProfilesInSpots(ids: List<String>): List<PrintProfile>
}