/* Ċ Ġ* ĠCopyright Ġ 2 0 2 0 ĠGoogle ĠLLC Ċ Ġ* Ċ Ġ* ĠLicensed Ġunder Ġthe ĠApache ĠLicense , ĠVersion Ġ 2 . 0 Ġ( the Ġ" License "); Ċ Ġ* Ġyou Ġmay Ġnot Ġuse Ġthis Ġfile Ġexcept Ġin Ġcompliance Ġwith Ġthe ĠLicense . Ċ Ġ* ĠYou Ġmay Ġobtain Ġa Ġcopy Ġof Ġthe ĠLicense Ġat Ċ Ġ* Ċ Ġ* ĠĠĠĠ Ġhttps :// www . apache . org / licenses / LICENSE - 2 . 0 Ċ Ġ* Ċ Ġ* ĠUnless Ġrequired Ġby Ġapplicable Ġlaw Ġor Ġagreed Ġto Ġin Ġwriting , Ġsoftware Ċ Ġ* Ġdistributed Ġunder Ġthe ĠLicense Ġis Ġdistributed Ġon Ġan Ġ" AS ĠIS " ĠBASIS , Ċ Ġ* ĠWITHOUT ĠWARRANTIES ĠOR ĠCONDITIONS ĠOF ĠANY ĠKIND , Ġeither Ġexpress Ġor Ġimplied . Ċ Ġ* ĠSee Ġthe ĠLicense Ġfor Ġthe Ġspecific Ġlanguage Ġgoverning Ġpermissions Ġand Ċ Ġ* Ġlimitations Ġunder Ġthe ĠLicense . Ċ Ġ*/ Ċ Ċ package Ġcom . dev rel . android . min w os Ċ Ċ import Ġandroid . app . Application Ċ import Ġandroid . app . Notification Manager Ċ import Ġandroid . content . Context Ċ import Ġandroid . net . Connectivity Manager Ċ import Ġandroid . os . V ibr ator Ċ import Ġandroid . tele phony . Subscription Manager Ċ import Ġandroid . tele phony . Tele phony Manager Ċ import Ġdagger . Module Ċ import Ġdagger . Provides Ċ import Ġdagger . h ilt . Install In Ċ import Ġdagger . h ilt . android . H ilt Android App Ċ import Ġdagger . h ilt . android . qual ifiers . ApplicationContext Ċ import Ġdagger . h ilt . components . Singleton Component Ċ import Ġjavax . inject . Singleton Ċ import Ġkotlinx . coroutines . Coroutine Dispatcher Ċ import Ġkotlinx . coroutines . Coroutine Scope Ċ import Ġkotlinx . coroutines . Dispatch ers Ċ import Ġkotlinx . coroutines . Supervisor Job Ċ Ċ @ H ilt Android App Ċ class ĠApp Ġ: ĠApplication () Ċ Ċ @ Module Ċ @ Install In ( Singleton Component :: class ) Ċ object ĠApp Module Ġ{ ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Connectivity Manager (@ ApplicationContext Ġcontext : ĠContext ) Ġ= ĊĠĠĠĠĠĠĠ Ġcontext . getSystem Service ( Connectivity Manager :: class . java ) !! ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Tele phony Manager (@ ApplicationContext Ġcontext : ĠContext ) Ġ= ĊĠĠĠĠĠĠĠ Ġcontext . getSystem Service ( Tele phony Manager :: class . java ) !! ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Notification Manager (@ ApplicationContext Ġcontext : ĠContext ) Ġ= ĊĠĠĠĠĠĠĠ Ġcontext . getSystem Service ( Notification Manager :: class . java ) !! ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Subscription Manager (@ ApplicationContext Ġcontext : ĠContext ) Ġ= ĊĠĠĠĠĠĠĠ Ġcontext . getSystem Service ( Subscription Manager :: class . java ) !! ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide V ibr ator (@ ApplicationContext Ġcontext : ĠContext ) Ġ= ĊĠĠĠĠĠĠĠ Ġcontext . getSystem Service ( V ibr ator :: class . java ) !! ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Dispatcher () Ġ= ĠDispatch ers . Default ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġfun Ġprovide Coroutine Scope ( coroutine Dispatcher : ĠCor outine Dispatcher ): ĠCor outine Scope Ġ= ĊĠĠĠĠĠĠĠ ĠCor outine Scope ( Supervisor Job () Ġ+ Ġcoroutine Dispatcher ) Ċ } Ċ