package Ġcom . pre cop ia . david . lists . widget . config view . build logic Ċ Ċ import Ġandroidx . lifecycle . ViewModel Ċ import Ġandroidx . lifecycle . ViewModel Provider Ċ import Ġcom . pre cop ia . david . lists . util . IS cheduler Provider Contract Ċ import Ġcom . pre cop ia . david . lists . widget . config view . I Widget Config Contract Ċ import Ġcom . pre cop ia . david . lists . widget . config view . Widget Config Logic Ċ import Ġcom . pre cop ia . domain . repository . I Repository Contract Ċ import Ġio . reactivex . rx java 3 . dis pos ables . Composite Disposable Ċ Ċ class ĠWidget Config Logic Factory ( ĊĠĠĠĠĠĠĠ Ġprivate Ġval ĠviewModel : ĠI Widget Config Contract . ViewModel , ĊĠĠĠĠĠĠĠ Ġprivate Ġval Ġrepo : ĠI Repository Contract . Repository , ĊĠĠĠĠĠĠĠ Ġprivate Ġval Ġscheduler Provider : ĠIS cheduler Provider Contract , ĊĠĠĠĠĠĠĠ Ġprivate Ġval Ġdis posable : ĠComposite Disposable Ċ ): ĠViewModel Provider . New Instance Factory () Ġ{ ĊĠĠĠ Ġ@ Suppress (" UN CHECK ED _ CAST ") ĊĠĠĠ Ġoverride Ġfun Ġ< T Ġ: ĠViewModel ?> Ġcreate ( model Class : ĠClass < T >): ĠT Ġ{ ĊĠĠĠĠĠĠĠ Ġreturn ĠWidget Config Logic ( viewModel , Ġrepo , Ġscheduler Provider , Ġdis posable ) Ġas ĠT ĊĠĠĠ Ġ} Ċ }