Lecture 12: Data Persistence

The lecture starts by considering how the state associated with an activity can be persisted across device configuration changes and process death. It goes on to consider the broad range of options available for both private storage (where the app alone has access to the data) and shared storage (where other apps, or the same app on other devices, have access). It looks at how files are written to and read from internal & external storage and then explores the use of SQLite databases via the Room persistence library. The lecture concludes with a brief look at how Google's Firestore can be used to store data in the cloud and have it sync automatically across devices.