package Ġcom . pad c my an mar . mm . health care . app . kotlin . tra . activities Ċ Ċ import Ġandroid . os . Bundle Ċ import Ġandroid . support . v 7 . app . AppCompatActivity Ċ import Ġandroid . support . v 7 . widget . Linear LayoutManager Ċ import Ġcom . pad c my an mar . mm . health care . app . kotlin . tra . R Ċ import Ġcom . pad c my an mar . mm . health care . app . kotlin . tra . adapters . Health care Info Adapter Ċ import Ġcom . pad c my an mar . mm . health care . app . kotlin . tra . data . models . Health care Info Model Ċ import Ġcom . pad c my an mar . mm . health care . app . kotlin . tra . data . v os . Health care Info VO Ċ import Ġcom . pad c my an mar . mm news . kotlin . events . Data Event Ċ import Ġkotlinx . android . synt hetic . main . activity _ health care _ info .* Ċ import Ġorg . green robot . event bus . EventBus Ċ import Ġorg . green robot . event bus . Subscribe Ċ import Ġorg . green robot . event bus . Thread Mode Ċ Ċ class ĠHealth care Info Activity Ġ: ĠAppCompatActivity () Ġ{ ĊĠĠĠ Ġprivate Ġvar Ġm Health care Info Adapter : ĠHealth care Info Adapter ? Ġ= Ġnull ĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ ĠsetContentView ( R . layout . activity _ health care _ info ) ĊĠĠĠĠĠĠĠ Ġset Support ActionBar ( toolbar ) ĊĊĠĠĠĠĠĠĠ Ġrv _ get _ health care _ info . layout Manager Ġ= ĠLinearLayoutManager ( application Context ) ĊĠĠĠĠĠĠĠ Ġm Health care Info Adapter Ġ= ĠHealth care Info Adapter ( application Context ) ĊĠĠĠĠĠĠĠ Ġrv _ get _ health care _ info . adapter Ġ= Ġm Health care Info Adapter ĊĊĠĠĠĠĠĠĠ ĠHealth care Info Model . getInstance (). load Health care Info () ĊĊĊĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun ĠonStart () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onStart () ĊĠĠĠĠĠĠĠ Ġif Ġ(! EventBus . getDefault (). is Registered ( this )) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠEvent Bus . getDefault (). register ( this ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġon Stop () Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . on Stop () ĊĠĠĠĠĠĠĠ Ġif Ġ( EventBus . getDefault (). is Registered ( this )) Ġ{ ĊĠĠĠĠĠĠĠĠĠĠĠ ĠEvent Bus . getDefault (). unregister ( this ) ĊĠĠĠĠĠĠĠ Ġ} ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Subscribe ( thread Mode Ġ= ĠThread Mode . MAIN ) ĊĠĠĠ Ġfun Ġon News Loaded Event ( health care Info Loaded Event : ĠData Event . Health care Info Loaded Event ) Ġ{ ĊĊĠĠĠĠĠĠĠ Ġm Health care Info Adapter !!. append New Data ( health care Info Loaded Event . loaded Health care Info Ġas ĠMutable List < Health care Info VO >) ĊĠĠĠ Ġ} Ċ }