package Ġcom . in nod roid . food scanner app . services . sc ans Ċ Ċ import Ġandroidx . lifecycle . LiveData Ċ import Ġandroidx . room . Dao Ċ import Ġandroidx . room . Insert Ċ import Ġandroidx . room . On Conflict Strategy Ċ import Ġandroidx . room . Query Ċ Ċ @ Dao Ċ interface ĠSc ans Dao Ġ{ ĊĠĠĠ Ġ@ Query (" SELECT Ġ* Ġfrom Ġscans ĠORDER ĠBY Ġdate ĠDESC ") ĊĠĠĠ Ġfun Ġget Sc ans (): ĠLive Data < List < Scan Stored >> ĊĊĠĠĠ Ġ@ Insert ( on Conflict Ġ= ĠOn Conflict Strategy . REPLACE ) ĊĠĠĠ Ġsuspend Ġfun Ġsave ( product : ĠScan Stored ) ĊĊĠĠĠ Ġ@ Query (" DELETE ĠFROM Ġscans Ġwhere Ġup c Ġin Ġ(: up cs )") ĊĠĠĠ Ġsuspend Ġfun Ġdelete ( up cs : ĠList < String >) Ċ } Ċ