Android internal storage when updating the application

I use the internal storage (http://developer.android.com/guide/topics/data/data-storage.html#filesInternal) to store some necessary application files that the user creates.

I believe these files are stored forever? They are only deleted when the user uninstalls the application, right?

In the case of updating the application (for example, from version 1.0 to 1.1) through the Android Market, what happens to files that were saved in the previous version? Are they deleted or not?

Thanks in advance.

+8
android storage internal
source share
2 answers

In the case of updating the application (for example, from version 1.0 to 1.1) through the Android Market, files that were saved from a previous version will be present on the device, and if you delete the application to get a new version, the files will be deleted.

+3
source share

The good question is, the documents actually do not say anything about any storage solutions that retain their data when updating. But just like SharedPreferences and the Sqlite database, I believe that this also persisted during the application update. The best way to make sure is to test it yourself. (I know this may seem rude because I want to tell you that “see for yourself.” But I will not mind this if my current machine is configured for Android development).

0
source share

All Articles