| java.lang.Object | ||
| ↳ | android.provider.Settings.NameValueTable | |
| ↳ | android.provider.Settings.Secure | |
Secure system settings, containing system preferences that applications can read but are not allowed to write. These are for preferences that the user must explicitly modify through the system UI or specialized APIs for those values, not modified directly by applications.
| Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| String | ACCESSIBILITY_DISPLAY_INVERSION_ENABLED | Setting that specifies whether display color inversion is enabled. | |||||||||
| String | ACCESSIBILITY_ENABLED | If accessibility is enabled. | |||||||||
| String | ACCESSIBILITY_SPEAK_PASSWORD | Whether to speak passwords while in accessibility mode. | |||||||||
| String | ADB_ENABLED | This constant was deprecated
      in API level 17.
    Use ADB_ENABLEDinstead | |||||||||
| String | ALLOWED_GEOLOCATION_ORIGINS | Origins for which browsers should allow geolocation by default. | |||||||||
| String | ALLOW_MOCK_LOCATION | Setting to allow mock locations and location provider status to be injected into the LocationManager service for testing purposes during application development. | |||||||||
| String | ANDROID_ID | A 64-bit number (as a hex string) that is randomly generated when the user first sets up the device and should remain constant for the lifetime of the user's device. | |||||||||
| String | BACKGROUND_DATA | This constant was deprecated
      in API level 14.
    As of ICE_CREAM_SANDWICH,
             availability of background data depends on several
             combined factors. When background data is unavailable,getActiveNetworkInfo()will
             now appear disconnected. | |||||||||
| String | BLUETOOTH_ON | This constant was deprecated
      in API level 17.
    Use BLUETOOTH_ONinstead | |||||||||
| String | DATA_ROAMING | This constant was deprecated
      in API level 17.
    Use DATA_ROAMINGinstead | |||||||||
| String | DEFAULT_INPUT_METHOD | Setting to record the input method used by default, holding the ID of the desired method. | |||||||||
| String | DEVELOPMENT_SETTINGS_ENABLED | This constant was deprecated
      in API level 17.
    Use DEVELOPMENT_SETTINGS_ENABLEDinstead | |||||||||
| String | DEVICE_PROVISIONED | This constant was deprecated
      in API level 17.
    Use DEVICE_PROVISIONEDinstead | |||||||||
| String | ENABLED_ACCESSIBILITY_SERVICES | List of the enabled accessibility providers. | |||||||||
| String | ENABLED_INPUT_METHODS | List of input methods that are currently enabled. | |||||||||
| String | HTTP_PROXY | This constant was deprecated
      in API level 17.
    Use HTTP_PROXY | |||||||||
| String | INPUT_METHOD_SELECTOR_VISIBILITY | Setting to record the visibility of input method selector | |||||||||
| String | INSTALL_NON_MARKET_APPS | Whether applications can be installed for this user via the system's ACTION_INSTALL_PACKAGEmechanism. | |||||||||
| String | LOCATION_MODE | The degree of location access enabled by the user. | |||||||||
| int | LOCATION_MODE_BATTERY_SAVING | Reduced power usage, such as limiting the number of GPS updates per hour. | |||||||||
| int | LOCATION_MODE_HIGH_ACCURACY | Best-effort location computation allowed. | |||||||||
| int | LOCATION_MODE_OFF | Location access disabled. | |||||||||
| int | LOCATION_MODE_SENSORS_ONLY | Network Location Provider disabled, but GPS and other sensors enabled. | |||||||||
| String | LOCATION_PROVIDERS_ALLOWED | This constant was deprecated
      in API level 19.
    use LOCATION_MODEandMODE_CHANGED_ACTION(orPROVIDERS_CHANGED_ACTION) | |||||||||
| String | LOCK_PATTERN_ENABLED | Whether autolock is enabled (0 = false, 1 = true) | |||||||||
| String | LOCK_PATTERN_TACTILE_FEEDBACK_ENABLED | This constant was deprecated
      in API level 17.
    Starting in JELLY_BEAN_MR1the
             lockscreen usesHAPTIC_FEEDBACK_ENABLED. | |||||||||
| String | LOCK_PATTERN_VISIBLE | Whether lock pattern is visible as user enters (0 = false, 1 = true) | |||||||||
| String | LOGGING_ID | This constant was deprecated in API level 3. This identifier is poorly initialized and has many collisions. It should not be used. | |||||||||
| String | NETWORK_PREFERENCE | This constant was deprecated
      in API level 17.
    Use NETWORK_PREFERENCEinstead | |||||||||
| String | PARENTAL_CONTROL_ENABLED | No longer supported. | |||||||||
| String | PARENTAL_CONTROL_LAST_UPDATE | No longer supported. | |||||||||
| String | PARENTAL_CONTROL_REDIRECT_URL | No longer supported. | |||||||||
| String | SELECTED_INPUT_METHOD_SUBTYPE | Setting to record the input method subtype used by default, holding the ID of the desired method. | |||||||||
| String | SETTINGS_CLASSNAME | Settings classname to launch when Settings is clicked from All Applications. | |||||||||
| String | SYS_PROP_SETTING_VERSION | ||||||||||
| String | TOUCH_EXPLORATION_ENABLED | If touch exploration is enabled. | |||||||||
| String | TTS_DEFAULT_COUNTRY | This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the default
 locale. getLanguage(). | |||||||||
| String | TTS_DEFAULT_LANG | This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the default
 locale. getLanguage(). | |||||||||
| String | TTS_DEFAULT_PITCH | Default text-to-speech engine pitch. | |||||||||
| String | TTS_DEFAULT_RATE | Default text-to-speech engine speech rate. | |||||||||
| String | TTS_DEFAULT_SYNTH | Default text-to-speech engine. | |||||||||
| String | TTS_DEFAULT_VARIANT | This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the
 locale that is in use getLanguage(). | |||||||||
| String | TTS_ENABLED_PLUGINS | Space delimited list of plugin packages that are enabled. | |||||||||
| String | TTS_USE_DEFAULTS | This constant was deprecated in API level 14. The value of this setting is no longer respected by the framework text to speech APIs as of the Ice Cream Sandwich release. | |||||||||
| String | USB_MASS_STORAGE_ENABLED | This constant was deprecated
      in API level 17.
    Use USB_MASS_STORAGE_ENABLEDinstead | |||||||||
| String | USE_GOOGLE_MAIL | This constant was deprecated
      in API level 17.
    Use USE_GOOGLE_MAILinstead | |||||||||
| String | WIFI_MAX_DHCP_RETRY_COUNT | This constant was deprecated
      in API level 17.
    Use WIFI_MAX_DHCP_RETRY_COUNTinstead | |||||||||
| String | WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS | This constant was deprecated
      in API level 17.
    Use WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MSinstead | |||||||||
| String | WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ON | This constant was deprecated
      in API level 17.
    Use WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ONinstead. | |||||||||
| String | WIFI_NETWORKS_AVAILABLE_REPEAT_DELAY | This constant was deprecated
      in API level 17.
    Use WIFI_NETWORKS_AVAILABLE_REPEAT_DELAYinstead. | |||||||||
| String | WIFI_NUM_OPEN_NETWORKS_KEPT | This constant was deprecated
      in API level 17.
    Use WIFI_NUM_OPEN_NETWORKS_KEPTinstead. | |||||||||
| String | WIFI_ON | This constant was deprecated
      in API level 17.
    Use WIFI_ONinstead. | |||||||||
| String | WIFI_WATCHDOG_ACCEPTABLE_PACKET_LOSS_PERCENTAGE | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_AP_COUNT | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_BACKGROUND_CHECK_DELAY_MS | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_BACKGROUND_CHECK_ENABLED | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_BACKGROUND_CHECK_TIMEOUT_MS | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_INITIAL_IGNORED_PING_COUNT | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_MAX_AP_CHECKS | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_ON | This constant was deprecated
      in API level 17.
    Use WIFI_WATCHDOG_ONinstead | |||||||||
| String | WIFI_WATCHDOG_PING_COUNT | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_PING_DELAY_MS | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_PING_TIMEOUT_MS | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| String | WIFI_WATCHDOG_WATCH_LIST | This constant was deprecated in API level 14. This setting is not used. | |||||||||
| [Expand] Inherited Constants | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
|  From class
android.provider.Settings.NameValueTable | |||||||||||
|  From interface
android.provider.BaseColumns | |||||||||||
| Fields | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| CONTENT_URI | The content:// style URL for this table | ||||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Convenience function for retrieving a single secure settings value
 as a floating point number. | |||||||||||
| Convenience function for retrieving a single secure settings value
 as a float. | |||||||||||
| Convenience function for retrieving a single secure settings value
 as an integer. | |||||||||||
| Convenience function for retrieving a single secure settings value
 as an integer. | |||||||||||
| Convenience function for retrieving a single secure settings value
 as a  long. | |||||||||||
| Convenience function for retrieving a single secure settings value
 as a  long. | |||||||||||
| Look up a name in the database. | |||||||||||
| Construct the content URI for a particular name/value pair,
 useful for monitoring changes with a ContentObserver. | |||||||||||
| 
      This method was deprecated
      in API level 19.
    use  LOCATION_MODEorisProviderEnabled(String) | |||||||||||
| Convenience function for updating a single settings value as a
 floating point number. | |||||||||||
| Convenience function for updating a single settings value as an
 integer. | |||||||||||
| Convenience function for updating a secure settings value as a long
 integer. | |||||||||||
| Store a name/value pair into the database. | |||||||||||
| 
      This method was deprecated
      in API level 19.
    use  putInt(ContentResolver, String, int)andLOCATION_MODE | |||||||||||
| [Expand] Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
|  From class
  android.provider.Settings.NameValueTable | |||||||||||
|  From class
  java.lang.Object | |||||||||||
Setting that specifies whether display color inversion is enabled.
If accessibility is enabled.
Whether to speak passwords while in accessibility mode.
Origins for which browsers should allow geolocation by default. The value is a space-separated list of origins.
Setting to allow mock locations and location provider status to be injected into the LocationManager service for testing purposes during application development. These locations and status values override actual location and status information generated by network, gps, or other location providers.
A 64-bit number (as a hex string) that is randomly generated when the user first sets up the device and should remain constant for the lifetime of the user's device. The value may change if a factory reset is performed on the device.
Note: When a device has multiple users
 (available on certain devices running Android 4.2 or higher), each user appears as a
 completely separate device, so the ANDROID_ID value is unique to each
 user.
      This constant was deprecated
      in API level 14.
    As of ICE_CREAM_SANDWICH,
             availability of background data depends on several
             combined factors. When background data is unavailable,
             getActiveNetworkInfo() will
             now appear disconnected.
  
Whether background data usage is allowed.
      This constant was deprecated
      in API level 17.
    Use BLUETOOTH_ON instead
  
      This constant was deprecated
      in API level 17.
    Use DATA_ROAMING instead
  
Setting to record the input method used by default, holding the ID of the desired method.
      This constant was deprecated
      in API level 17.
    Use DEVELOPMENT_SETTINGS_ENABLED
 instead
  
      This constant was deprecated
      in API level 17.
    Use DEVICE_PROVISIONED instead
  
List of the enabled accessibility providers.
List of input methods that are currently enabled. This is a string containing the IDs of all enabled input methods, each ID separated by ':'.
      This constant was deprecated
      in API level 17.
    Use HTTP_PROXY
  
Host name and port for global http proxy. Uses ':' seperator for between host and port.
Setting to record the visibility of input method selector
Whether applications can be installed for this user via the system's
 ACTION_INSTALL_PACKAGE mechanism.
 
1 = permit app installation via the system package installer intent
0 = do not allow use of the package installer
The degree of location access enabled by the user.
 When used with putInt(ContentResolver, String, int), must be one of LOCATION_MODE_HIGH_ACCURACY, LOCATION_MODE_SENSORS_ONLY, LOCATION_MODE_BATTERY_SAVING, or LOCATION_MODE_OFF. When used with getInt(ContentResolver, String), the caller must gracefully handle additional location
 modes that might be added in the future.
 
 Note: do not rely on this value being present in settings.db or on ContentObserver
 notifications for the corresponding Uri. Use MODE_CHANGED_ACTION
 to receive changes in this value.
Reduced power usage, such as limiting the number of GPS updates per hour. Requests
 with POWER_HIGH may be downgraded to
 POWER_MEDIUM.
Best-effort location computation allowed.
Location access disabled.
Network Location Provider disabled, but GPS and other sensors enabled.
      This constant was deprecated
      in API level 19.
    use LOCATION_MODE and
 MODE_CHANGED_ACTION (or
 PROVIDERS_CHANGED_ACTION)
  
Comma-separated list of location providers that activities may access. Do not rely on this value being present in settings.db or on ContentObserver notifications on the corresponding Uri.
Whether autolock is enabled (0 = false, 1 = true)
      This constant was deprecated
      in API level 17.
    Starting in JELLY_BEAN_MR1 the
             lockscreen uses
             HAPTIC_FEEDBACK_ENABLED.
  
Whether lock pattern will vibrate as user enters (0 = false, 1 = true)
Whether lock pattern is visible as user enters (0 = false, 1 = true)
      This constant was deprecated
      in API level 3.
    This identifier is poorly initialized and has
 many collisions.  It should not be used.
  
The Logging ID (a unique 64-bit value) as a hex string. Used as a pseudonymous identifier for logging.
      This constant was deprecated
      in API level 17.
    Use NETWORK_PREFERENCE instead
  
No longer supported.
No longer supported.
No longer supported.
Setting to record the input method subtype used by default, holding the ID of the desired method.
Settings classname to launch when Settings is clicked from All Applications. Needed because of user testing between the old and new Settings apps.
If touch exploration is enabled.
      This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the default
 locale. getLanguage().
  
Default text-to-speech country.
      This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the default
 locale. getLanguage().
  
Default text-to-speech language.
Default text-to-speech engine pitch. 100 = 1x
Default text-to-speech engine speech rate. 100 = 1x
Default text-to-speech engine.
      This constant was deprecated
      in API level 14.
    this setting is no longer in use, as of the Ice Cream
 Sandwich release. Apps should never need to read this setting directly,
 instead can query the TextToSpeech framework classes for the
 locale that is in use getLanguage().
  
Default text-to-speech locale variant.
Space delimited list of plugin packages that are enabled.
      This constant was deprecated
      in API level 14.
    The value of this setting is no longer respected by
 the framework text to speech APIs as of the Ice Cream Sandwich release.
  
Setting to always use the default text-to-speech settings regardless of the application settings. 1 = override application settings, 0 = use application settings (if specified).
      This constant was deprecated
      in API level 17.
    Use USB_MASS_STORAGE_ENABLED instead
  
      This constant was deprecated
      in API level 17.
    Use USE_GOOGLE_MAIL instead
  
      This constant was deprecated
      in API level 17.
    Use
 WIFI_MAX_DHCP_RETRY_COUNT instead
  
      This constant was deprecated
      in API level 17.
    Use
 WIFI_MOBILE_DATA_TRANSITION_WAKELOCK_TIMEOUT_MS instead
  
      This constant was deprecated
      in API level 17.
    Use WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ON
 instead.
  
      This constant was deprecated
      in API level 17.
    Use WIFI_NETWORKS_AVAILABLE_REPEAT_DELAY
 instead.
  
      This constant was deprecated
      in API level 17.
    Use WIFI_NUM_OPEN_NETWORKS_KEPT
 instead.
  
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The acceptable packet loss percentage (range 0 - 100) before trying another AP on the same network.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The number of access points required for a network in order for the watchdog to monitor it.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The delay between background checks.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
Whether the Wi-Fi watchdog is enabled for background checking even after it thinks the user has connected to a good access point.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The timeout for a background ping
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The number of initial pings to perform that *may* be ignored if they fail. Again, if these fail, they will *not* be used in packet loss calculation. For example, one network always seemed to time out for the first couple pings, so this is set to 3 by default.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The maximum number of access points (per network) to attempt to test. If this number is reached, the watchdog will no longer monitor the initial connection state for the network. This is a safeguard for networks containing multiple APs whose DNS does not respond to pings.
      This constant was deprecated
      in API level 17.
    Use WIFI_WATCHDOG_ON instead
  
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The number of pings to test if an access point is a good connection.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The delay between pings.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
The timeout per ping.
      This constant was deprecated
      in API level 14.
    This setting is not used.
  
A comma-separated list of SSIDs for which the Wi-Fi watchdog should be enabled.
Convenience function for retrieving a single secure settings value as a floating point number. Note that internally setting values are always stored as strings; this function converts the string to an float for you. The default value will be returned if the setting is not defined or not a valid float.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| def | Value to return if the setting is not defined. | 
Convenience function for retrieving a single secure settings value as a float. Note that internally setting values are always stored as strings; this function converts the string to a float for you.
 This version does not take a default value.  If the setting has not
 been set, or the string value is not a number,
 it throws Settings.SettingNotFoundException.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| Settings.SettingNotFoundException | Thrown if a setting by the given name can't be found or the setting value is not a float. | 
|---|
Convenience function for retrieving a single secure settings value as an integer. Note that internally setting values are always stored as strings; this function converts the string to an integer for you.
 This version does not take a default value.  If the setting has not
 been set, or the string value is not a number,
 it throws Settings.SettingNotFoundException.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| Settings.SettingNotFoundException | Thrown if a setting by the given name can't be found or the setting value is not an integer. | 
|---|
Convenience function for retrieving a single secure settings value as an integer. Note that internally setting values are always stored as strings; this function converts the string to an integer for you. The default value will be returned if the setting is not defined or not an integer.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| def | Value to return if the setting is not defined. | 
Convenience function for retrieving a single secure settings value
 as a long.  Note that internally setting values are always
 stored as strings; this function converts the string to a long
 for you.  The default value will be returned if the setting is
 not defined or not a long.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| def | Value to return if the setting is not defined. | 
long.
Convenience function for retrieving a single secure settings value
 as a long.  Note that internally setting values are always
 stored as strings; this function converts the string to a long
 for you.
 
 This version does not take a default value.  If the setting has not
 been set, or the string value is not a number,
 it throws Settings.SettingNotFoundException.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to retrieve. | 
| Settings.SettingNotFoundException | Thrown if a setting by the given name can't be found or the setting value is not an integer. | 
|---|
Look up a name in the database.
| resolver | to access the database with | 
|---|---|
| name | to look up in the table | 
Construct the content URI for a particular name/value pair, useful for monitoring changes with a ContentObserver.
| name | to look up in the table | 
|---|
      This method was deprecated
      in API level 19.
    use LOCATION_MODE or
             isProviderEnabled(String)
  
Helper method for determining if a location provider is enabled.
| cr | the content resolver to use | 
|---|---|
| provider | the location provider to query | 
Convenience function for updating a single settings value as a floating point number. This will either create a new entry in the table if the given name does not exist, or modify the value of the existing row with that name. Note that internally setting values are always stored as strings, so this function converts the given value to a string before storing it.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to modify. | 
| value | The new value for the setting. | 
Convenience function for updating a single settings value as an integer. This will either create a new entry in the table if the given name does not exist, or modify the value of the existing row with that name. Note that internally setting values are always stored as strings, so this function converts the given value to a string before storing it.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to modify. | 
| value | The new value for the setting. | 
Convenience function for updating a secure settings value as a long integer. This will either create a new entry in the table if the given name does not exist, or modify the value of the existing row with that name. Note that internally setting values are always stored as strings, so this function converts the given value to a string before storing it.
| cr | The ContentResolver to access. | 
|---|---|
| name | The name of the setting to modify. | 
| value | The new value for the setting. | 
Store a name/value pair into the database.
| resolver | to access the database with | 
|---|---|
| name | to store | 
| value | to associate with the name | 
      This method was deprecated
      in API level 19.
    use putInt(ContentResolver, String, int) and LOCATION_MODE
  
Thread-safe method for enabling or disabling a single location provider.
| cr | the content resolver to use | 
|---|---|
| provider | the location provider to enable or disable | 
| enabled | true if the provider should be enabled |