Search code examples
androidsqlitepreferences

Saving large amount of android settings


I have an app that has a large chunk of settings consisting of 7 string arrays, 3 strings and a date.Is it recommended to store it into a sqlite db or can I use the preference or is there any other alternative?


Solution

  • Recommended storage for settings and preferences in android is Preferences, you can save StringArray into preference by converting it to Set first, then store into preferences, by method:

    prefEditor.putStringSet("key", set);