danielmbutler / RoomPicker

MVVM, NetworkBoundResource, RoomDB, TypeConverters, RoomTesting, SingleLiveEvent Class

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Room_Picker_App

Images

Architecure

MVVM with LiveData and Network Bound Resource Single source of truth for item retrieval , all results from the api are cached on the local Room Database and returned to the activites/fragments, cache is only cleared when the timestamp expires or if the DB returns empty results (Manual Override in settings)

API/RoomDB -> Repository -> ViewModel -> Fragments/Activities alt text

Caching Screenshots

Log showing that timestamp has expired on room object so the app will retrieve items from api.

alt text

Manual override for clearing cache.

About

MVVM, NetworkBoundResource, RoomDB, TypeConverters, RoomTesting, SingleLiveEvent Class


Languages

Language:Kotlin 100.0%