Lines Matching refs:name

554      * Input: The Intent's data URI specifies the application package name
1021 * Common base for tables of name/value settings.
1024 public static final String NAME = "name";
1028 String name, String value) {
1032 values.put(NAME, name);
1037 Log.w(TAG, "Can't set key " + name + " in " + uri, e);
1042 public static Uri getUriFor(Uri uri, String name) {
1043 return Uri.withAppendedPath(uri, name);
1054 private static final String NAME_EQ_PLACEHOLDER = "name=?";
1087 public boolean putStringForUser(ContentResolver cr, String name, String value,
1094 cp.call(cr.getPackageName(), mCallSetCommand, name, arg);
1096 Log.w(TAG, "Can't set key " + name + " in " + mUri, e);
1102 public String getStringForUser(ContentResolver cr, String name, final int userHandle) {
1119 if (mValues.containsKey(name)) {
1120 return mValues.get(name); // Could be null, that's OK -- negative caching
1141 Bundle b = cp.call(cr.getPackageName(), mCallGetCommand, name, args);
1147 mValues.put(name, value);
1167 new String[]{name}, null, null);
1169 Log.w(TAG, "Can't get key " + name + " from " + mUri);
1175 mValues.put(name, value);
1179 name + " = " + (value == null ? "(null)" : value));
1183 Log.w(TAG, "Can't get key " + name + " from " + mUri, e);
1193 * table holds simple name/value pairs. There are convenience
1313 * Look up a name in the database.
1315 * @param name to look up in the table
1318 public static String getString(ContentResolver resolver, String name) {
1319 return getStringForUser(resolver, name, UserHandle.myUserId());
1323 public static String getStringForUser(ContentResolver resolver, String name,
1325 if (MOVED_TO_SECURE.contains(name)) {
1326 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1328 return Secure.getStringForUser(resolver, name, userHandle);
1330 if (MOVED_TO_GLOBAL.contains(name) || MOVED_TO_SECURE_THEN_GLOBAL.contains(name)) {
1331 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1333 return Global.getStringForUser(resolver, name, userHandle);
1335 return sNameValueCache.getStringForUser(resolver, name, userHandle);
1339 * Store a name/value pair into the database.
1341 * @param name to store
1342 * @param value to associate with the name
1345 public static boolean putString(ContentResolver resolver, String name, String value) {
1346 return putStringForUser(resolver, name, value, UserHandle.myUserId());
1350 public static boolean putStringForUser(ContentResolver resolver, String name, String value,
1352 if (MOVED_TO_SECURE.contains(name)) {
1353 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1357 if (MOVED_TO_GLOBAL.contains(name) || MOVED_TO_SECURE_THEN_GLOBAL.contains(name)) {
1358 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1362 return sNameValueCache.putStringForUser(resolver, name, value, userHandle);
1366 * Construct the content URI for a particular name/value pair,
1368 * @param name to look up in the table
1371 public static Uri getUriFor(String name) {
1372 if (MOVED_TO_SECURE.contains(name)) {
1373 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1375 return Secure.getUriFor(Secure.CONTENT_URI, name);
1377 if (MOVED_TO_GLOBAL.contains(name) || MOVED_TO_SECURE_THEN_GLOBAL.contains(name)) {
1378 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
1380 return Global.getUriFor(Global.CONTENT_URI, name);
1382 return getUriFor(CONTENT_URI, name);
1393 * @param name The name of the setting to retrieve.
1399 public static int getInt(ContentResolver cr, String name, int def) {
1400 return getIntForUser(cr, name, def, UserHandle.myUserId());
1404 public static int getIntForUser(ContentResolver cr, String name, int def, int userHandle) {
1405 String v = getStringForUser(cr, name, userHandle);
1424 * @param name The name of the setting to retrieve.
1427 * name can't be found or the setting value is not an integer.
1431 public static int getInt(ContentResolver cr, String name)
1433 return getIntForUser(cr, name, UserHandle.myUserId());
1437 public static int getIntForUser(ContentResolver cr, String name, int userHandle)
1439 String v = getStringForUser(cr, name, userHandle);
1443 throw new SettingNotFoundException(name);
1450 * given name does not exist, or modify the value of the existing row
1451 * with that name. Note that internally setting values are always
1456 * @param name The name of the setting to modify.
1460 public static boolean putInt(ContentResolver cr, String name, int value) {
1461 return putIntForUser(cr, name, value, UserHandle.myUserId());
1465 public static boolean putIntForUser(ContentResolver cr, String name, int value,
1467 return putStringForUser(cr, name, Integer.toString(value), userHandle);
1478 * @param name The name of the setting to retrieve.
1484 public static long getLong(ContentResolver cr, String name, long def) {
1485 return getLongForUser(cr, name, def, UserHandle.myUserId());
1489 public static long getLongForUser(ContentResolver cr, String name, long def,
1491 String valString = getStringForUser(cr, name, userHandle);
1512 * @param name The name of the setting to retrieve.
1516 * name can't be found or the setting value is not an integer.
1518 public static long getLong(ContentResolver cr, String name)
1520 return getLongForUser(cr, name, UserHandle.myUserId());
1524 public static long getLongForUser(ContentResolver cr, String name, int userHandle)
1526 String valString = getStringForUser(cr, name, userHandle);
1530 throw new SettingNotFoundException(name);
1537 * given name does not exist, or modify the value of the existing row
1538 * with that name. Note that internally setting values are always
1543 * @param name The name of the setting to modify.
1547 public static boolean putLong(ContentResolver cr, String name, long value) {
1548 return putLongForUser(cr, name, value, UserHandle.myUserId());
1552 public static boolean putLongForUser(ContentResolver cr, String name, long value,
1554 return putStringForUser(cr, name, Long.toString(value), userHandle);
1565 * @param name The name of the setting to retrieve.
1571 public static float getFloat(ContentResolver cr, String name, float def) {
1572 return getFloatForUser(cr, name, def, UserHandle.myUserId());
1576 public static float getFloatForUser(ContentResolver cr, String name, float def,
1578 String v = getStringForUser(cr, name, userHandle);
1597 * @param name The name of the setting to retrieve.
1600 * name can't be found or the setting value is not a float.
1604 public static float getFloat(ContentResolver cr, String name)
1606 return getFloatForUser(cr, name, UserHandle.myUserId());
1610 public static float getFloatForUser(ContentResolver cr, String name, int userHandle)
1612 String v = getStringForUser(cr, name, userHandle);
1614 throw new SettingNotFoundException(name);
1619 throw new SettingNotFoundException(name);
1626 * table if the given name does not exist, or modify the value of the
1627 * existing row with that name. Note that internally setting values
1632 * @param name The name of the setting to modify.
1636 public static boolean putFloat(ContentResolver cr, String name, float value) {
1637 return putFloatForUser(cr, name, value, UserHandle.myUserId());
1641 public static boolean putFloatForUser(ContentResolver cr, String name, float value,
1643 return putStringForUser(cr, name, Float.toString(value), userHandle);
3111 * Look up a name in the database.
3113 * @param name to look up in the table
3116 public static String getString(ContentResolver resolver, String name) {
3117 return getStringForUser(resolver, name, UserHandle.myUserId());
3121 public static String getStringForUser(ContentResolver resolver, String name,
3123 if (MOVED_TO_GLOBAL.contains(name)) {
3124 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.Secure"
3126 return Global.getStringForUser(resolver, name, userHandle);
3129 if (MOVED_TO_LOCK_SETTINGS.contains(name)) {
3139 return sLockSettings.getString(name, "0", userHandle);
3146 return sNameValueCache.getStringForUser(resolver, name, userHandle);
3150 * Store a name/value pair into the database.
3152 * @param name to store
3153 * @param value to associate with the name
3156 public static boolean putString(ContentResolver resolver, String name, String value) {
3157 return putStringForUser(resolver, name, value, UserHandle.myUserId());
3161 public static boolean putStringForUser(ContentResolver resolver, String name, String value,
3163 if (LOCATION_MODE.equals(name)) {
3168 if (MOVED_TO_GLOBAL.contains(name)) {
3169 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
3171 return Global.putStringForUser(resolver, name, value, userHandle);
3173 return sNameValueCache.putStringForUser(resolver, name, value, userHandle);
3177 * Construct the content URI for a particular name/value pair,
3179 * @param name to look up in the table
3182 public static Uri getUriFor(String name) {
3183 if (MOVED_TO_GLOBAL.contains(name)) {
3184 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.Secure"
3186 return Global.getUriFor(Global.CONTENT_URI, name);
3188 return getUriFor(CONTENT_URI, name);
3199 * @param name The name of the setting to retrieve.
3205 public static int getInt(ContentResolver cr, String name, int def) {
3206 return getIntForUser(cr, name, def, UserHandle.myUserId());
3210 public static int getIntForUser(ContentResolver cr, String name, int def, int userHandle) {
3211 if (LOCATION_MODE.equals(name)) {
3216 String v = getStringForUser(cr, name, userHandle);
3235 * @param name The name of the setting to retrieve.
3238 * name can't be found or the setting value is not an integer.
3242 public static int getInt(ContentResolver cr, String name)
3244 return getIntForUser(cr, name, UserHandle.myUserId());
3248 public static int getIntForUser(ContentResolver cr, String name, int userHandle)
3250 if (LOCATION_MODE.equals(name)) {
3255 String v = getStringForUser(cr, name, userHandle);
3259 throw new SettingNotFoundException(name);
3266 * given name does not exist, or modify the value of the existing row
3267 * with that name. Note that internally setting values are always
3272 * @param name The name of the setting to modify.
3276 public static boolean putInt(ContentResolver cr, String name, int value) {
3277 return putIntForUser(cr, name, value, UserHandle.myUserId());
3281 public static boolean putIntForUser(ContentResolver cr, String name, int value,
3283 return putStringForUser(cr, name, Integer.toString(value), userHandle);
3294 * @param name The name of the setting to retrieve.
3300 public static long getLong(ContentResolver cr, String name, long def) {
3301 return getLongForUser(cr, name, def, UserHandle.myUserId());
3305 public static long getLongForUser(ContentResolver cr, String name, long def,
3307 String valString = getStringForUser(cr, name, userHandle);
3328 * @param name The name of the setting to retrieve.
3332 * name can't be found or the setting value is not an integer.
3334 public static long getLong(ContentResolver cr, String name)
3336 return getLongForUser(cr, name, UserHandle.myUserId());
3340 public static long getLongForUser(ContentResolver cr, String name, int userHandle)
3342 String valString = getStringForUser(cr, name, userHandle);
3346 throw new SettingNotFoundException(name);
3353 * given name does not exist, or modify the value of the existing row
3354 * with that name. Note that internally setting values are always
3359 * @param name The name of the setting to modify.
3363 public static boolean putLong(ContentResolver cr, String name, long value) {
3364 return putLongForUser(cr, name, value, UserHandle.myUserId());
3368 public static boolean putLongForUser(ContentResolver cr, String name, long value,
3370 return putStringForUser(cr, name, Long.toString(value), userHandle);
3381 * @param name The name of the setting to retrieve.
3387 public static float getFloat(ContentResolver cr, String name, float def) {
3388 return getFloatForUser(cr, name, def, UserHandle.myUserId());
3392 public static float getFloatForUser(ContentResolver cr, String name, float def,
3394 String v = getStringForUser(cr, name, userHandle);
3413 * @param name The name of the setting to retrieve.
3416 * name can't be found or the setting value is not a float.
3420 public static float getFloat(ContentResolver cr, String name)
3422 return getFloatForUser(cr, name, UserHandle.myUserId());
3426 public static float getFloatForUser(ContentResolver cr, String name, int userHandle)
3428 String v = getStringForUser(cr, name, userHandle);
3430 throw new SettingNotFoundException(name);
3435 throw new SettingNotFoundException(name);
3442 * table if the given name does not exist, or modify the value of the
3443 * existing row with that name. Note that internally setting values
3448 * @param name The name of the setting to modify.
3452 public static boolean putFloat(ContentResolver cr, String name, float value) {
3453 return putFloatForUser(cr, name, value, UserHandle.myUserId());
3457 public static boolean putFloatForUser(ContentResolver cr, String name, float value,
3459 return putStringForUser(cr, name, Float.toString(value), userHandle);
3593 * Host name and port for global http proxy. Uses ':' seperator for
4456 * installed. This setting is stored as a flattened component name as
4739 * Specifies the package name currently configured to be the primary sms application
4808 * List of custom TV input labels. This is a string containing <TV input id, custom name>
4809 * pairs. TV input id and custom name are encoded by {@link android.net.Uri#encode(String)}
4973 // to ensure thread safety, we write the provider name with a '+' or '-'
5503 * Which package name to use for network scoring. If null, or if the package is not a valid
5713 * "name,apn,proxy,port,username,password,server,mmsc,mmsproxy,mmsport,mcc,mnc,auth,type"
5714 * note that empty fields can be ommitted: "name,apn,,,,,,,,,310,260,,DUN"
5915 * The Wi-Fi peer-to-peer device name
6231 * Host name and port for global http proxy. Uses ':' seperator for
6237 * Host name for global http proxy. Set via ConnectivityManager.
6593 * The name of the device
6699 * Look up a name in the database.
6701 * @param name to look up in the table
6704 public static String getString(ContentResolver resolver, String name) {
6705 return getStringForUser(resolver, name, UserHandle.myUserId());
6709 public static String getStringForUser(ContentResolver resolver, String name,
6711 if (MOVED_TO_SECURE.contains(name)) {
6712 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.Global"
6714 return Secure.getStringForUser(resolver, name, userHandle);
6716 return sNameValueCache.getStringForUser(resolver, name, userHandle);
6720 * Store a name/value pair into the database.
6722 * @param name to store
6723 * @param value to associate with the name
6727 String name, String value) {
6728 return putStringForUser(resolver, name, value, UserHandle.myUserId());
6733 String name, String value, int userHandle) {
6735 Log.v(TAG, "Global.putString(name=" + name + ", value=" + value
6739 if (MOVED_TO_SECURE.contains(name)) {
6740 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.Global"
6742 return Secure.putStringForUser(resolver, name, value, userHandle);
6744 return sNameValueCache.putStringForUser(resolver, name, value, userHandle);
6748 * Construct the content URI for a particular name/value pair,
6750 * @param name to look up in the table
6753 public static Uri getUriFor(String name) {
6754 return getUriFor(CONTENT_URI, name);
6765 * @param name The name of the setting to retrieve.
6771 public static int getInt(ContentResolver cr, String name, int def) {
6772 String v = getString(cr, name);
6791 * @param name The name of the setting to retrieve.
6794 * name can't be found or the setting value is not an integer.
6798 public static int getInt(ContentResolver cr, String name)
6800 String v = getString(cr, name);
6804 throw new SettingNotFoundException(name);
6811 * given name does not exist, or modify the value of the existing row
6812 * with that name. Note that internally setting values are always
6817 * @param name The name of the setting to modify.
6821 public static boolean putInt(ContentResolver cr, String name, int value) {
6822 return putString(cr, name, Integer.toString(value));
6833 * @param name The name of the setting to retrieve.
6839 public static long getLong(ContentResolver cr, String name, long def) {
6840 String valString = getString(cr, name);
6861 * @param name The name of the setting to retrieve.
6865 * name can't be found or the setting value is not an integer.
6867 public static long getLong(ContentResolver cr, String name)
6869 String valString = getString(cr, name);
6873 throw new SettingNotFoundException(name);
6880 * given name does not exist, or modify the value of the existing row
6881 * with that name. Note that internally setting values are always
6886 * @param name The name of the setting to modify.
6890 public static boolean putLong(ContentResolver cr, String name, long value) {
6891 return putString(cr, name, Long.toString(value));
6902 * @param name The name of the setting to retrieve.
6908 public static float getFloat(ContentResolver cr, String name, float def) {
6909 String v = getString(cr, name);
6928 * @param name The name of the setting to retrieve.
6931 * name can't be found or the setting value is not a float.
6935 public static float getFloat(ContentResolver cr, String name)
6937 String v = getString(cr, name);
6939 throw new SettingNotFoundException(name);
6944 throw new SettingNotFoundException(name);
6951 * table if the given name does not exist, or modify the value of the
6952 * existing row with that name. Note that internally setting values
6957 * @param name The name of the setting to modify.
6961 public static boolean putFloat(ContentResolver cr, String name, float value) {
6962 return putString(cr, name, Float.toString(value));
7037 * Descriptive name of the bookmark that can be displayed to the user.
7052 * the folder name does not change so you can consistently query for
7159 * Return the folder name as it should be displayed to the user. This