package Ġcom . gor illa . attendance . data . db Ċ Ċ import Ġandroidx . room . Dao Ċ import Ġandroidx . room . Insert Ċ import Ġandroidx . room . On Conflict Strategy Ċ import Ġandroidx . room . Query Ċ import Ġcom . gor illa . attendance . data . model . Attendance DeviceInfo Data Ċ import Ġcom . gor illa . attendance . data . model . DeviceId entities Data Ċ import Ġio . reactivex . Flow able Ċ import Ġio . reactivex . Single ĊĊ Ċ @ Dao Ċ abstract Ġclass ĠDevice Id entities Dao Ġ{ ĊĠĠĠ Ġ@ Insert ( on Conflict Ġ= ĠOn Conflict Strategy . REPLACE ) ĊĠĠĠ Ġabstract Ġfun Ġinsert DeviceId entities Data ( deviceId entities Data : ĠDevice Id entities Data ?) ĊĊĠĠĠ Ġ@ Query (" SELECT Ġ* ĠFROM ĠDevice Id entities Data ĠWHERE Ġdevice Token Ġ= Ġ: device Token ") ĊĠĠĠ Ġabstract Ġfun Ġget DeviceId entities Data ( device Token : ĠString ?): ĠFlow able < DeviceId entities Data > ĊĊĠĠĠ Ġ@ Insert ( on Conflict Ġ= ĠOn Conflict Strategy . REPLACE ) ĊĠĠĠ Ġabstract Ġfun Ġinsert DeviceInfo Data ( device Info Data : ĠAtt endance DeviceInfo Data ?) ĊĊĠĠĠ Ġ@ Query (" SELECT Ġ* ĠFROM ĠAtt endance DeviceInfo Data ĠWHERE Ġdevice Token Ġ= Ġ: device Token ") ĊĠĠĠ Ġabstract Ġfun Ġsearch Device By Device Token ( device Token : ĠString ?): ĠSingle < List < Attendance DeviceInfo Data >> Ċ }