关于Settings.Global /Secure/System

关于Settings.Global /Secure/System    目前来看区别不大

Settings.db是系统的一个Provider,可以获取或者修改里面的数据值,这几个表都可以存储String,Int等类型的值,数据类型不受限制

系统可能会根据不同的数据进行分类

如果添加自己的数据,写在哪个表里都行,数据的获取和修改是需要的权限以及字段名的长度的限制

直接看代码

 /**
1128     * @hide - Private call() method on SettingsProvider to read from 'system' table.
1129     */
1130    public static final String CALL_METHOD_GET_SYSTEM = "GET_system";
1131
1132    /**
1133     * @hide - Private call() method on SettingsProvider to read from 'secure' table.
1134     */
1135    public static final String CALL_METHOD_GET_SECURE = "GET_secure";
1136
1137    /**
1138     * @hide - Private call() method on SettingsProvider to read from 'global' table.
1139     */
1140    public static final String CALL_METHOD_GET_GLOBAL = "GET_global";
1141
1142    /**
1143     * @hide - User handle argument extra to the fast-path call()-based requests
1144     */
1145    public static final String CALL_METHOD_USER_KEY = "_user";
1146
1147    /** @hide - Private call() method to write to 'system' table */
1148    public static final String CALL_METHOD_PUT_SYSTEM = "PUT_system";
1149
1150    /** @hide - Private call() method to write to 'secure' table */
1151    public static final String CALL_METHOD_PUT_SECURE = "PUT_secure";
1152
1153    /** @hide - Private call() method to write to 'global' table */
1154    public static final String CALL_METHOD_PUT_GLOBAL= "PUT_global";

你可能感兴趣的:(android)