1

My company provides a number of Android applications that all need a central preferences entity. For example "user_id" which is an integer that would be the same across all applications. Now the user can have 1 or any number of my company's applications installed in any order. What we've been doing is having a central file in the sdcard/Android/data directory. But this can be cumbersome as this external directory may need to be removed at uninstall time. I would like to provide a solution where uninstalling this external directory would not be necessary. My first choice is a ContentProvider. But where we can have 1 or more applications installed in any order, I'm not sure this is feasible. And ALSO what would happen if you installed application 'A' which has a content provider, and then installed application 'B' which I guess would use that content provider provided by 'A', and after that user uninstalls application 'A'? Being that I'm not an expert at content providers in Android, is this the way to go? Would there be another way I could do this without using an external file? Thanks /Loren

Loren Rogers
  • 325
  • 3
  • 13
  • Well, something like Firebase comes to mind (database + auth). I'm not sure if it allows shared databases though. – Shaishav Aug 28 '16 at 13:41

0 Answers0