package Ġcom . example . br uno . recyclerview training Ċ Ċ import Ġandroid . support . v 7 . app . AppCompatActivity Ċ import Ġandroid . os . Bundle Ċ import Ġandroid . support . v 7 . widget . Linear LayoutManager Ċ import Ġcom . example . br uno . recyclerview training . model . Fly Ċ import Ġkotlinx . android . synt hetic . main . activity _ main .* Ċ Ċ class ĠMainActivity Ġ: ĠAppCompatActivity (), ĠList F lies Contract . List F lies View Ġ{ ĊĊĠĠĠ Ġprivate Ġval Ġpresenter : ĠList F lies Contract . List F lies Presenter Ġ= ĠList F lies Presenter Impl ( this ) ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ ĠsetContentView ( R . layout . activity _ main ) ĊĊĠĠĠĠĠĠĠ Ġpresenter . retrieve F lies () ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġfill F lies In List ( f lies : ĠArrayList < Fly >) Ġ{ ĊĠĠĠĠĠĠĠ Ġvar Ġlayout Manager Ġ= ĠLinearLayoutManager ( this ) ĊĊĠĠĠĠĠĠĠ Ġvar Ġadapter Ġ= ĠFly Adapter ( f lies , Ġthis ) ĊĊĠĠĠĠĠĠĠ Ġre cycler _ view _ id . layout Manager Ġ= Ġlayout Manager ĊĠĠĠĠĠĠĠ Ġre cycler _ view _ id . adapter Ġ= Ġadapter ĊĊĠĠĠĠĠĠĠ Ġadapter . notify DataSet Changed () ĊĠĠĠ Ġ} Ċ } Ċ