Storing and retrieving data 126

5.1 Using preferences 127

Working with SharedPreferences 127 ■ Preference access permissions 130

5.2 Using the filesystem 134

Creating files 134 ■ Accessing files 135 ■ Files as raw resources 136 ■ XML file resources 137 ■ External storage via an SD card 139

5.3 Persisting data to a database 143

Building and accessing a database 143 ■ Using the sqlite3 tool 148

5.4 Working with ContentProvider classes 149

Understanding URI representations and manipulating records 151 Creating a ContentProvider 158

5.5 Summary 165

0 0

Post a comment