views:

15

answers:

0

What is the best and simplest way to have persistent data on android for a 'favourtes' tab?

I have three types of objects which can be found on three different tabs and the user can choose to 'star' them and they get added to a favourites list. I'm not to sure what the best way of doing this is...

Currently I'm adding the items to three different SharedPreferences and serializing the object and saving to the internal memory. And reading them back when the favourites tab activity is launched. But there doesn't seem to be a simple way to have all the features that you would expect without making the code more and more complex (like removing things from fav list while outside the fav activity, and not having to reload all objects when a change happens, etc.)

Any Ideas?