Book Image

Xamarin Mobile Application Development for Android, Second Edition

Book Image

Xamarin Mobile Application Development for Android, Second Edition

Overview of this book

Table of Contents (18 chapters)
Xamarin Mobile Application Development for Android Second Edition
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Data storage in Android


Android supports several solutions that can be used for persisting data locally. The persisted data can be accessible even when the application shuts down or when a device restarts. The examples of such data include the device settings, contacts list, browser bookmarks, or any such app-specific data.

The following table depicts the different data storage options available in the Android platform:

Storage options

Description

Shared preferences

This is the private data storage for your application that persists primitive key-value data pairs only. When the user uninstalls the application, this data is removed.

Internal storage

This stores data in the device internal memory and is available until the app is uninstalled from the device. This data is private to your application and other apps cannot access it.

External file storage

This stores data in shared external storage such as an external SD card. The data stored is public. Other applications or users can...