package Ġru . deb ajo . reader . rss . data . db . dao Ċ Ċ import Ġandroidx . room . Dao Ċ import Ġandroidx . room . Insert Ċ import Ġandroidx . room . On Conflict Strategy Ċ import Ġandroidx . room . Query Ċ import Ġkotlinx . coroutines . flow . Flow Ċ import Ġru . deb ajo . reader . rss . data . db . model . Db New Article Ċ Ċ @ Dao Ċ interface ĠNew Articles Dao Ġ{ ĊĠĠĠ Ġ@ Insert ( on Conflict Ġ= ĠOn Conflict Strategy . REPLACE ) ĊĠĠĠ Ġsuspend Ġfun Ġinsert ( articles : ĠList < Db New Article >) ĊĊĠĠĠ Ġ@ Query (" DELETE ĠFROM Ġdb new article ĠWHERE Ġarticle Id ĠIN Ġ(: article Ids )") ĊĠĠĠ Ġsuspend Ġfun Ġremove ( article Ids : ĠList < String >) ĊĊĠĠĠ Ġ@ Query (" DELETE ĠFROM Ġdb new article ĠWHERE Ġchannel Url ĠIN Ġ(: channel Url )") ĊĠĠĠ Ġsuspend Ġfun Ġremove By Channel Url ( channel Url : ĠString ) ĊĊĠĠĠ Ġ@ Query (" SELECT Ġarticle Id ĠFROM Ġdb new article ĠWHERE Ġchannel Url ĠIN Ġ( SELECT Ġurl ĠFROM Ġdb channel subscription )") ĊĠĠĠ Ġsuspend Ġfun ĠgetAll Ids (): ĠList < String > ĊĊĠĠĠ Ġ@ Query (" SELECT Ġarticle Id ĠFROM Ġdb new article ĠWHERE Ġchannel Url ĠIN Ġ( SELECT Ġurl ĠFROM Ġdb channel subscription )") ĊĠĠĠ Ġfun Ġobserve Ids (): ĠFlow < List < String >> ĊĊĠĠĠ Ġ@ Query (" DELETE ĠFROM Ġdb new article ") ĊĠĠĠ Ġsuspend Ġfun Ġremove All () Ċ } Ċ