使用SystemProperties获取系统属性以及数据库读写操作

来源:互联网 发布:mysql连接时间 编辑:程序博客网 时间:2024/06/03 20:18

在使用SystemProperties.get("ro.build.product", "~~~");获取系统属性的时候,

需要把SDK中的layoutlib.jar导入到当前工程。


数据库问题:

Settings.System.putInt(mContext.getContentResolver(), "isStarted_AttrNameService", 1);//写入值

Settings.System.putInt(getContentResolver(), "isStarted_AttrNameService", 1);//写入值

Settings.System.getInt(mContentResolver, "start_stringId_tool", 0);//读取值



0 0
原创粉丝点击