/* Ċ Ġ* ĠCopyright Ġ 2 0 2 1 ĠLe ah ĠN ich ita Ċ Ġ* Ċ Ġ* Ġ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 . fer elin . data _ network _ api . di Ċ Ċ import Ġandroid . content . Context Ċ import Ġcom . fer elin . data _ network _ api . R Ċ import Ġcom . fer elin . data _ network _ api . builder . Ret rofit Builder Ċ import Ġcom . fer elin . data _ network _ api . entities . Crypto Price Api Ċ import Ġcom . fer elin . data _ network _ api . entities . News Api Ċ import Ġcom . fer elin . data _ network _ api . entities . Past Prices Api Ċ import Ġcom . fer elin . data _ network _ api . entities . Stock Price Api Ċ import Ġcom . fer elin . shared . NAMED _ CRYPTO _ RET RO FIT Ċ import Ġcom . fer elin . shared . NAMED _ CRYPTO _ TOKEN Ċ import Ġcom . fer elin . shared . NAMED _ STO CK S _ RET RO FIT Ċ import Ġcom . fer elin . shared . NAMED _ STO CK S _ TOKEN Ċ import Ġdagger . Module Ċ import Ġdagger . Provides Ċ import Ġretrofit 2 . Ret rofit Ċ import Ġjavax . inject . Named Ċ import Ġjavax . inject . Singleton Ċ Ċ @ Module Ċ class ĠNetwork Api Module Ġ{ ĊĊĠĠĠ Ġ@ Named ( NAMED _ STO CK S _ RET RO FIT ) ĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Sto cks Ret rofit (): ĠRet rofit Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn ĠRet rofit Builder . build ( Ret rofit Builder . FIN NH UB _ BASE _ URL ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Named ( NAMED _ CRYPTO _ RET RO FIT ) ĊĠĠĠ Ġ@ Singleton ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Crypto Ret rofit (): ĠRet rofit Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn ĠRet rofit Builder . build ( Ret rofit Builder . NO M ICS _ BASE _ URL ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide News Api (@ Named ( NAMED _ STO CK S _ RET RO FIT ) Ġretrofit : ĠRet rofit ): ĠNews Api Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġretrofit . create ( News Api :: class . java ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Stock Price Api (@ Named ( NAMED _ STO CK S _ RET RO FIT ) Ġretrofit : ĠRet rofit ): ĠStock Price Api Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġretrofit . create ( Stock Price Api :: class . java ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Past Price Api (@ Named ( NAMED _ STO CK S _ RET RO FIT ) Ġretrofit : ĠRet rofit ): ĠP ast Prices Api Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġretrofit . create ( Past Prices Api :: class . java ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Crypto Price Api (@ Named ( NAMED _ CRYPTO _ RET RO FIT ) Ġretrofit : ĠRet rofit ): ĠCrypto Price Api Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġretrofit . create ( Crypto Price Api :: class . java ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Named ( NAMED _ STO CK S _ TOKEN ) ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Fin n hub Token ( context : ĠContext ): ĠString Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcontext . resources . getString ( R . string . api _ fin n hub _ token ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Named ( NAMED _ CRYPTO _ TOKEN ) ĊĠĠĠ Ġ@ Provides ĊĠĠĠ Ġfun Ġprovide Crypto Token ( context : ĠContext ): ĠString Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn Ġcontext . resources . getString ( R . string . api _ nom ics _ token ) ĊĠĠĠ Ġ} Ċ }