Join David Gassner for an in-depth discussion in this video Creating and reading files in internal storage, part of Android App Development: Local Data Storage (2013).
The Android SDK includes all of the tools you need to create and read files.…You can create binary or text files.…And for text files, you can use your own arbitrary format, or you can use common…structured data formats, such as JSON and XML.…The files can be placed in either internal or external storage.…This refers to whether the file is local to the application or shared with…other applications.…I'll start with internal files.…I'm working in a version of the project called Internal Storage.…
This project has an Edit Text control in the layout and then two buttons at the…bottom labeled Create file and Read file.…And there's also a TextView object at the bottom that I'll use to…output information.…I'll go to the MainActivity class.…I'll expand to full screen, and I'll start in the onCreate method, after the existing code.…In order to work with internal files, the first step is to create an instance of the file class.…This is the same file class that's used in all Java code.…
It represents either a directory or file, and in this case it will represent…
- Exploring local data storage options
- Creating an Android virtual device
- Starting a new project
- Defining preferences with Java and activities
- Creating and reading JSON and XML data files
- Creating a new SQLite database
- Inserting and retrieving data in the database
Skill Level Intermediate
1. Getting Started
2. Using Application Preferences
3. Using Internal and External File Storage
4. Working with SQLite Databases
5. Managing and Displaying SQLite Data
Improving the data display9m 29s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.