package Ġcom . openj its u . android . openj its u . di . modules Ċ Ċ import Ġandroid . app . Activity Ċ import Ġandroid . app . Application Ċ import Ġandroid . content . Context Ċ import Ġandroid . content . SharedPreferences Ċ import Ġdagger . Module Ċ import Ġdagger . Provides Ċ import Ġkotlinx . coroutines . Coroutine Scope Ċ import Ġkotlinx . coroutines . Dispatch ers Ċ import Ġjavax . inject . Singleton Ċ Ċ @ Module ( includes Ġ= Ġ[ Data Module :: class ]) Ċ class ĠApp Module ( private Ġval Ġapplication : ĠApplication ) Ġ{ ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġfun Ġprovide Context (): ĠContext Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġapplication . application Context ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide SharedPreferences ( context : ĠContext ): ĠSharedPreferences Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcontext . get SharedPreferences (" openj its u ", ĠActivity . MODE _ PRIVATE ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Main Coroutine Scope (): ĠCor outine Scope Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn ĠCor outine Scope ( Dispatch ers . Main ) ĊĠĠĠ Ġ} ĊĊ Ċ }