I have a class Settings
with static methods which I use to save and load my data. This is for example the Save()
method:
public static void Save(SETTING_KEY key, String value)
{
SharedPreferences sp = _context.getSharedPreferences(prefName, Context.MODE_PRIVATE);
SharedPreferences.Editor editor = sp.edit();
editor.putString(key.toString(), value);
editor.commit();
}
Now I'd like to make the class Settings
observable. The problem is that extending my Settings-class from Observable does not work, as I don't instantiate this class as I only use its static methods.
Is there any easy way to make this static class observable?