package Ġdev . edu ay uso . cle ans ample s . mv vm app . components . ui Ċ Ċ import Ġandroid . os . Bundle Ċ import Ġandroid . os . Persist able Bundle Ċ import Ġandroidx . appcompat . app . AppCompatActivity Ċ import Ġandroidx . databinding . Data Binding Util Ċ import Ġandroidx . databinding . ViewData Binding Ċ import Ġdev . edu ay uso . cle ans ample s . mv vm app . BR Ċ import Ġdev . edu ay uso . cle ans ample s . shared . presentation . mv vm . Clean ViewModel Ċ Ċ abstract Ġclass ĠClean Activity < Binding Class Ġ: ĠView Data Binding >: ĠAppCompatActivity () Ġ{ ĊĊĠĠĠ Ġprotected Ġlateinit Ġvar Ġbinding : ĠBinding Class ĊĠĠĠ Ġabstract Ġval ĠviewModel : ĠClean ViewModel ĊĠĠĠ Ġabstract Ġval Ġlayout ResourceId : ĠInt ĊĊĠĠĠ Ġoverride Ġfun ĠonCreate ( savedInstanceState : ĠBundle ?) Ġ{ ĊĊĠĠĠĠĠĠĠ Ġsuper . onCreate ( savedInstanceState ) ĊĠĠĠĠĠĠĠ Ġbinding Ġ= ĠData Binding Util . set ContentView ( this , Ġlayout ResourceId ) ĊĠĠĠĠĠĠĠ Ġbinding . set Variable ( BR . viewModel , ĠviewModel ) ĊĠĠĠĠĠĠĠ Ġbinding . lifecycle Owner Ġ= Ġthis ĊĠĠĠĠĠĠĠ Ġbinding . execute Pending Bindings () ĊĊĠĠĠĠĠĠĠ Ġsupport ActionBar ?. set Display Home As Up Enabled ( true ) ĊĠĠĠĠĠĠĠ Ġsupport ActionBar ?. set Display Show Home Enabled ( true ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġoverride Ġfun Ġon Support Navigate Up (): ĠBoolean Ġ{ ĊĠĠĠĠĠĠĠ Ġthis . finish () ĊĠĠĠĠĠĠĠ Ġreturn Ġtrue ĊĠĠĠ Ġ} Ċ }