Searched refs:preferences (Results 1 - 8 of 8) sorted by relevance
/foundation/distributeddatamgr/preferences/test/js/unittest/preferences/src/ |
H A D | PreferencesHelperSyncJsunit.test.js | 16 import data_preferences from '@ohos.data.preferences' 39 let preferences = data_preferences.getPreferencesSync(context, { name: NAME }); 40 preferences.putSync(KEY_TEST_STRING_ELEMENT, "132"); 41 expect(preferences.hasSync(KEY_TEST_STRING_ELEMENT)).assertTrue(); 42 let val = preferences.getSync(KEY_TEST_STRING_ELEMENT, "defaultvalue"); 53 let preferences = data_preferences.getPreferencesSync(context, NAME); 54 preferences.putSync(KEY_TEST_STRING_ELEMENT, "132"); 55 expect(preferences.hasSync(KEY_TEST_STRING_ELEMENT)).assertTrue(); 56 let val = preferences.getSync(KEY_TEST_STRING_ELEMENT, "defaultvalue"); 58 preferences [all...] |
/foundation/distributeddatamgr/preferences/test/native/unittest/ |
H A D | preferences_helper_test.cpp | 25 #include "preferences.h" 147 std::shared_ptr<Preferences> preferences = PreferencesHelper::GetPreferences(option, errCode); in HWTEST_F() local 148 EXPECT_EQ(preferences, nullptr); in HWTEST_F() 149 preferences = nullptr; in HWTEST_F() 159 Options option = Options("/data/test/preferences/test01", "", ""); in HWTEST_F() 161 std::shared_ptr<Preferences> preferences = PreferencesHelper::GetPreferences(option, errCode); in HWTEST_F() local 162 EXPECT_EQ(preferences, nullptr); in HWTEST_F() 163 preferences = nullptr; in HWTEST_F()
|
H A D | preferences_test.cpp | 16 #include "preferences.h" 174 std::shared_ptr<Preferences> preferences = PreferencesHelper::GetPreferences(option, errCode); in HWTEST_F() local 176 EXPECT_EQ(preferences->GetGroupId(), "2002001"); in HWTEST_F() 178 preferences = nullptr; in HWTEST_F()
|
/foundation/distributeddatamgr/preferences/frameworks/cj/src/ |
H A D | preferences_impl.cpp | 24 #include "preferences.h" 76 LOGE("Failed to get underlying preferences instance."); in PreferencesImpl() 79 preferences = proxy; in PreferencesImpl() 80 if (preferences == nullptr) { in PreferencesImpl() 81 LOGE("The preferences is nullptr."); in PreferencesImpl() 116 if (preferences == nullptr) { in Flush() 117 LOGE("The preferences is nullptr."); in Flush() 120 preferences->FlushSync(); in Flush() 126 if (preferences == nullptr) { in Clear() 127 LOGE("The preferences i in Clear() [all...] |
H A D | preferences_impl.h | 20 #include "preferences.h" 83 std::shared_ptr<NativePreferences::Preferences> preferences; member in OHOS::Preferences::PreferencesImpl
|
/foundation/bundlemanager/app_domain_verify/frameworks/common/src/config/ |
H A D | white_list_config_mgr.cpp | 98 std::shared_ptr<NativePreferences::Preferences> preferences = NativePreferences::PreferencesHelper::GetPreferences( in GetPreference() local 104 return preferences; in GetPreference() 110 APP_DOMAIN_VERIFY_HILOGW(APP_DOMAIN_VERIFY_MODULE_COMMON, "preferences null"); in Save()
|
/foundation/distributeddatamgr/preferences/frameworks/ndk/include/ |
H A D | oh_preferences_impl.h | 23 #include "preferences.h" 53 explicit OH_PreferencesImpl(std::shared_ptr<OHOS::NativePreferences::Preferences> preferences);
|
/foundation/distributeddatamgr/preferences/frameworks/ndk/src/ |
H A D | oh_preferences.cpp | 33 (std::shared_ptr<OHOS::NativePreferences::Preferences> preferences) : preferences_(preferences) in OH_PreferencesImpl() 60 LOG_ERROR("get system preferences dir failed, err: %{public}d", err); in GetPreferencesDir() 130 LOG_ERROR("preferences is null: %{public}d when get native preferences from ohPreferences", in GetNativePreferencesFromOH() 158 LOG_ERROR("preferences close failed, preferences is null"); in OH_Preferences_Close() 32 OH_PreferencesImpl(std::shared_ptr<OHOS::NativePreferences::Preferences> preferences) OH_PreferencesImpl() argument
|
Completed in 5 milliseconds