SharedPreferences 查询和获取
1.boolean contains(String key)
2.abstract Map<String, ?> getAll()
3.boolean getXxx(String key, xx defValue)
SharedPreferences.Editor增删数据
1.SharedPreferences.Editor clear()
2.SharedPreferences.Editor putXxx(String key, xxx value)
3.SharedPreferences.Eidtor remove(String key)
4.boolean commit()
SharedPreferences对象
SharedPreferences是一个接口,所以不能实例化对象。可以通过getSharedPreferences()方法
SharedPreferences preferences = getSharedPreferences(String name, MODE_PRIVATE);