package Ġj er ma ine . data . articles Ċ Ċ import Ġio . reactivex . Comp letable Ċ import Ġio . reactivex . Single Ċ import Ġio . reactivex . schedul ers . Schedulers Ċ import Ġj er ma ine . data . articles . db . Articles Dao Ċ import Ġj er ma ine . data . articles . service . Articles Service Ċ import Ġj er ma ine . domain . articles . Articles Repository Ċ import Ġj er ma ine . domain . articles . model . Article Ċ import Ġjavax . inject . Inject Ċ import Ġjavax . inject . Singleton Ċ Ċ @ Singleton Ċ class ĠArticles Repository Impl Ġ@ Inject Ġconstructor ( ĊĠĠĠĠĠĠĠ Ġprivate Ġval Ġarticles Service : ĠArticles Service , ĊĠĠĠĠĠĠĠ Ġprivate Ġval Ġarticles Dao : ĠArticles Dao Ċ ) Ġ: ĠArticles Repository Ġ{ ĊĊĠĠĠ Ġoverride Ġfun Ġfetch Articles ( page : ĠInt ): ĠSingle < List < Article >> Ġ= ĊĠĠĠĠĠĠĠĠĠĠĠ Ġarticles Service . fetch Articles ( page ) ĊĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠĠ Ġ. subscribe On ( Schedulers . io ()) ĊĊĠĠĠ Ġoverride Ġfun Ġbook Mark Article ( article : ĠArticle ): ĠComp letable Ġ= ĊĠĠĠĠĠĠĠĠĠĠĠ Ġarticles Dao . book Mark Article ( article ) ĊĊĠĠĠ Ġoverride Ġfun Ġfetch Book Marked Articles ( page : ĠInt ): ĠSingle < List < Article >> Ġ= ĊĠĠĠĠĠĠĠĠĠĠĠ Ġarticles Dao . fetch Book marked Articles ( page ) ĊĊĠĠĠ Ġoverride Ġfun Ġfetch All Book Marked Articles (): ĠSingle < List < Article >> Ġ= ĊĠĠĠĠĠĠĠĠĠĠĠ Ġarticles Dao . fetch All Book marked Articles () ĊĊĠĠĠ Ġoverride Ġfun Ġremove Book marked Article ( article : ĠArticle ): ĠComp letable Ġ= ĊĠĠĠĠĠĠĠĠĠĠĠ Ġarticles Dao . remove Book marked Article ( article ) Ċ } Ċ