Persisting Data
In the previous chapter, you learned how to structure your code and save data. In the activity section, Activity 11.01 – a shopping notes app, you also had the opportunity to build a repository and use it to access and save data through Room
. In this chapter, you will learn about alternative ways to store and access data on an Android device’s internal and external memory.
You’ll develop your understanding of read and write permissions, learn how to create the FileProvider
class to offer other apps access to your files, and learn how you can save those files without requesting permissions on external drives. You’ll also see how to download files from the internet and save them on a filesystem.
Another concept that will be explored in this chapter is using the Camera application to take photos and videos on your application’s behalf and save them to external storage using FileProvider
.
This chapter goes in depth about data...