2

I'm maintaining an app that uses Shared Preferences.

Normal settings are got from getDefaultSharedPreferences. I would like to store another set of preferentes (user session info, completely unrelated with the other settings), using getSharedPreferences.

If I do that, there's any chance of one cause interference on another?

Fabricio Araujo
  • 3,750
  • 3
  • 26
  • 42
  • Probably duplicate of [Difference between getDefaultSharedPreferences and getSharedPreferences](http://stackoverflow.com/questions/5946135/difference-between-getdefaultsharedpreferences-and-getsharedpreferences) – ρяσѕρєя K Feb 20 '15 at 16:29

1 Answers1

1

If I do that, there's any chance of one cause interference on another?

no there is not such a thing. They are stored in two different xml files (unless you are so lucky to guess the default name, context.getPackageName() + "_preferences").

Blackbelt
  • 152,872
  • 27
  • 286
  • 297