package Ġcom . em ami . mov ied b . movie . data . local čĊč Ċ import Ġandroidx . paging . Paging Source č Ċ import Ġcom . em ami . mov ied b . movie . data . local . dao . Movie Dao č Ċ import Ġcom . em ami . mov ied b . movie . data . local . dao . Remote Keys Dao č Ċ import Ġcom . em ami . mov ied b . movie . data . local . entity . Movie Entity č Ċ import Ġcom . em ami . mov ied b . movie . data . local . entity . Remote Keys Entity č Ċ import Ġjavax . inject . Inject čĊč Ċ class ĠLocal DataSource Impl Ġ@ Inject Ġconstructor ( čĊĠĠĠ Ġprivate Ġval Ġmovie Dao : ĠMovie Dao , čĊĠĠĠ Ġprivate Ġval Ġremote Keys Dao : ĠRemote Keys Dao č Ċ ) Ġ: ĠLocal DataSource Ġ{ čĊĠĠĠ Ġoverride Ġsuspend Ġfun Ġinsert All Keys ( list : ĠList < Remote Keys Entity >) Ġ{ čĊĠĠĠĠĠĠĠ Ġremote Keys Dao . insert All ( list ) čĊĠĠĠ Ġ} čĊčĊĠĠĠ Ġoverride Ġfun ĠgetAll Movies (): ĠP aging Source < Int , ĠMovie Entity > Ġ{ čĊĠĠĠĠĠĠĠ Ġreturn Ġmovie Dao . getAll Movies () čĊĠĠĠ Ġ} čĊčĊĠĠĠ Ġoverride Ġsuspend Ġfun Ġinsert All Movies ( list : ĠList < Movie Entity >) Ġ{ čĊĠĠĠĠĠĠĠ Ġmovie Dao . insert All ( list ) čĊĠĠĠ Ġ} čĊčĊĠĠĠ Ġoverride Ġsuspend Ġfun Ġfind Remote Key ById ( id : ĠLong ): ĠRemote Keys Entity ? Ġ{ čĊĠĠĠĠĠĠĠ Ġreturn Ġremote Keys Dao . get Remote Key ById ( id ) čĊĠĠĠ Ġ} čĊčĊĠĠĠ Ġoverride Ġsuspend Ġfun Ġfind Movie ById ( id : ĠLong ): ĠMovie Entity ? Ġ{ čĊĠĠĠĠĠĠĠ Ġreturn Ġmovie Dao . get Movie ById ( id ) čĊĠĠĠ Ġ} čĊčĊĠĠĠ Ġoverride Ġsuspend Ġfun Ġclear All Tables () Ġ{ čĊĠĠĠĠĠĠĠ Ġmovie Dao . clear Movies () čĊĠĠĠĠĠĠĠ Ġremote Keys Dao . clear Remote Keys () čĊĠĠĠ Ġ} č Ċ }