Android Components under the hood
summary
Explains how Lifecycle, LiveData, ViewModel and Room are implemented rather than just named. Notes 700 ms delay in ProcessLifecycleOwner to avoid false background events. Shows LiveData increments a version on setValue, requires main thread, while postValue posts to the main thread and costs a thread hop and getValue can be null. Describes ViewModelStore coming from getLastNonConfigurationInstance and Room generating DAOs as _Impl classes that bind entities to SQLite using cursors and adapters, with deletes matching only the primary key.
AI-written summary · about
chapters (8)
- 0:00Introduction
- 1:11Lifecycle
- 6:45Live Data
- 10:17ViewModel
- 10:50Configuration Changes
- 17:34Room
- 23:25Database
- 24:18Conclusion
related talks
47mAndroid Architecture Component
44mARCH Components
44mAndroid Architecture Components, a New Way to Build Apps
41mViewModels, LiveData and Lifecycles, oh my!
23mLifecycle, LiveData, Viewmodels - The inner wiring
33mThe A,B and C of Lifecycle Components
28mInternals of Android Architecture Components
48mArchitecture Components – Behind the Scenes
