Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What Room does (Entity – DAO – Database – Repository – ViewModel – UI)

Room persists weather data: Entity defines table rows, DAO declares queries, AppDatabase provides the database, Repository wraps DAO, ViewModel exposes flows, and the UI observes ViewModel state.

Project structure

Project structure: network/ data/ repository/ ui/ (MainActivity + ViewModel) and build configuration in build.gradle.kts.

How data flows

Data flow: user enters city -> ViewModel fetches network -> on success ViewModel calls Repository -> Repository/DAO insert into Room -> UI observes entries via StateFlow.

Cache / caching logic

Cache logic: Room stores each successful fetch.

https://www.youtube.com/watch?v=68mz5bO9Plw

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages