11. Persisting Data
Overview
This chapter goes in depth about data persistence in Android, as well as exploring the repository pattern. By the end of the chapter, you will be able to build a repository that can connect to multiple data sources, and then use this repository to download files from an API and save them on a device. You will know multiple ways to store (persist) data directly on a device and the frameworks accessible to do this. When dealing with a filesystem, you will learn how it's partitioned and how you can read and write files in different locations and using different frameworks.