Lines Matching refs:key
204 const string& key = it.key(); in ConvertDictionaryValueToVariantDictionary() local
208 LOG(ERROR) << "Key |" << key << "| has unsupported TYPE_NULL."; in ConvertDictionaryValueToVariantDictionary()
213 (*variant_dictionary)[key] = native_bool; in ConvertDictionaryValueToVariantDictionary()
219 (*variant_dictionary)[key] = native_int; in ConvertDictionaryValueToVariantDictionary()
223 LOG(ERROR) << "Key |" << key << "| has unsupported TYPE_DOUBLE."; in ConvertDictionaryValueToVariantDictionary()
228 (*variant_dictionary)[key] = native_string; in ConvertDictionaryValueToVariantDictionary()
233 LOG(ERROR) << "Key |" << key << "| has unexpected TYPE_BINARY."; in ConvertDictionaryValueToVariantDictionary()
239 LOG(ERROR) << "Key |" << key << "| has unsupported TYPE_DICTIONARY."; in ConvertDictionaryValueToVariantDictionary()
245 LOG(ERROR) << "Key |" << key << "| could not be decoded."; in ConvertDictionaryValueToVariantDictionary()
248 (*variant_dictionary)[key] = *decoded_coerced_value; in ConvertDictionaryValueToVariantDictionary()
258 LOG(ERROR) << "Key |" << key << "| could not be decoded."; in ConvertDictionaryValueToVariantDictionary()
261 (*variant_dictionary)[key] = *string_list; in ConvertDictionaryValueToVariantDictionary()
302 const auto& key = key_and_value.first; in ConvertVariantDictionaryToDictionaryValue() local
305 dictionary_value->SetBooleanWithoutPathExpansion(key, value.Get<bool>()); in ConvertVariantDictionaryToDictionaryValue()
307 dictionary_value->SetIntegerWithoutPathExpansion(key, value.Get<int>()); in ConvertVariantDictionaryToDictionaryValue()
310 key, MakeValueForString(value.Get<string>())); in ConvertVariantDictionaryToDictionaryValue()
315 key, MakeCoercedValue(kNativeTypeUint64, encoded_value)); in ConvertVariantDictionaryToDictionaryValue()
321 dictionary_value->SetWithoutPathExpansion(key, std::move(list_value)); in ConvertVariantDictionaryToDictionaryValue()
323 LOG(ERROR) << "Failed to convert element with key |" << key << "|."; in ConvertVariantDictionaryToDictionaryValue()
401 const string& group_name = it.key(); in Open()
486 set<string> JsonStore::GetGroupsWithKey(const string& key) const { in GetGroupsWithKey()
492 if (group_settings.find(key) != group_settings.end()) { in GetGroupsWithKey()
518 bool JsonStore::DeleteKey(const string& group, const string& key) { in DeleteKey() argument
526 auto property_it = group_settings.find(key); in DeleteKey()
548 const string& key, in GetString() argument
550 return ReadSetting(group, key, value); in GetString()
554 const string& group, const string& key, const string& value) { in SetString() argument
555 return WriteSetting(group, key, value); in SetString()
558 bool JsonStore::GetBool(const string& group, const string& key, bool* value) in GetBool() argument
560 return ReadSetting(group, key, value); in GetBool()
563 bool JsonStore::SetBool(const string& group, const string& key, bool value) { in SetBool() argument
564 return WriteSetting(group, key, value); in SetBool()
568 const string& group, const string& key, int* value) const { in GetInt() argument
569 return ReadSetting(group, key, value); in GetInt()
572 bool JsonStore::SetInt(const string& group, const string& key, int value) { in SetInt() argument
573 return WriteSetting(group, key, value); in SetInt()
577 const string& group, const string& key, uint64_t* value) const { in GetUint64() argument
578 return ReadSetting(group, key, value); in GetUint64()
582 const string& group, const string& key, uint64_t value) { in SetUint64() argument
583 return WriteSetting(group, key, value); in SetUint64()
587 const string& group, const string& key, vector<string>* value) const { in GetStringList() argument
588 return ReadSetting(group, key, value); in GetStringList()
592 const string& group, const string& key, const vector<string>& value) { in SetStringList() argument
593 return WriteSetting(group, key, value); in SetStringList()
597 const string& group, const string& key, string* value) { in GetCryptedString() argument
599 if (!GetString(group, key, &encrypted_value)) { in GetCryptedString()
612 << ":|" << key << "|."; in GetCryptedString()
623 const string& group, const string& key, const string& value) { in SetCryptedString() argument
628 << ":|" << key << "|."; in SetCryptedString()
632 return SetString(group, key, encrypted_value); in SetCryptedString()
638 const string& group, const string& key, T* out) const { in ReadSetting() argument
646 const auto& property_name_and_value = group_settings.find(key); in ReadSetting()
648 SLOG(this, 10) << "Could not find property |" << key << "|."; in ReadSetting()
671 const string& group, const string& key, const T& new_value) { in WriteSetting() argument
674 group_name_to_settings_[group][key] = new_value; in WriteSetting()
679 auto property_name_and_value = group_settings.find(key); in WriteSetting()
681 group_settings[key] = new_value; in WriteSetting()