Home
last modified time | relevance | path

Searched refs:adminName (Results 1 – 13 of 13) sorted by relevance

/base/customization/enterprise_device_management/services/edm/src/
Dpolicy_manager.cpp60 bool PolicyManager::ParseAdminList(const std::string &adminName, const PolicyItemsMap &itemsMap) in ParseAdminList() argument
69 adminValueItem.insert(std::pair<std::string, std::string>(adminName, policyValue)); in ParseAdminList()
73 auto iterValue = adminValueRef.find(adminName); in ParseAdminList()
76 adminName.c_str(), policyName.c_str()); in ParseAdminList()
79 adminValueRef.insert(std::pair<std::string, std::string>(adminName, policyValue)); in ParseAdminList()
88 std::string adminName; in ParseAdminPolicy() local
96 adminName = admin["AdminName"].asString(); in ParseAdminPolicy()
101 if (admin.isMember("PolicyItems") && admin["PolicyItems"].isObject() && !adminName.empty()) { in ParseAdminPolicy()
103 adminPolicies_.insert(std::pair<std::string, PolicyItemsMap>(adminName, itemsMap)); in ParseAdminPolicy()
104 isParseAdminListSuccess = ParseAdminList(adminName, itemsMap); in ParseAdminPolicy()
[all …]
Denterprise_device_mgr_ability.cpp407 ErrCode EnterpriseDeviceMgrAbility::RemoveAdminItem(std::string adminName, std::string policyName, in RemoveAdminItem() argument
416 if ((ret = plugin->OnAdminRemove(adminName, policyValue)) != ERR_OK) { in RemoveAdminItem()
418 adminName.c_str(), policyValue.c_str(), ret); in RemoveAdminItem()
422 if ((ret = plugin->MergePolicyData(adminName, mergedPolicyData)) != ERR_OK) { in RemoveAdminItem()
433 setRet = policyMgr_->SetPolicy(adminName, policyName, "", mergedPolicyData); in RemoveAdminItem()
438 adminName.c_str(), policyName.c_str(), ret); in RemoveAdminItem()
442 plugin->OnAdminRemoveDone(adminName, policyValue); in RemoveAdminItem()
446 ErrCode EnterpriseDeviceMgrAbility::RemoveAdmin(const std::string &adminName, int32_t userId) in RemoveAdmin() argument
448 EDMLOGD("RemoveAdmin %{public}s, user id = %{public}d", adminName.c_str(), userId); in RemoveAdmin()
450 policyMgr_->GetAllPolicyByAdmin(adminName, policyItems); in RemoveAdmin()
[all …]
Diplugin.cpp47 ErrCode IPlugin::MergePolicyData(const std::string &adminName, std::string &mergeJsonData) in MergePolicyData() argument
Dadmin_manager.cpp276 … std::string adminName = item->adminInfo_.packageName_ + "/" + item->adminInfo_.className_; in GetEnabledAdmin() local
277 packageNameList.push_back(adminName); in GetEnabledAdmin()
/base/customization/enterprise_device_management/services/edm/include/
Dpolicy_manager.h52 ErrCode GetAllPolicyByAdmin(const std::string &adminName, PolicyItemsMap &allAdminPolicy);
64 …ErrCode GetPolicy(const std::string &adminName, const std::string &policyName, std::string &policy…
79 …ErrCode SetPolicy(const std::string &adminName, const std::string &policyName, const std::string &…
118 bool DeleteAdminPolicyItemJsonValue(Json::Value &admin, const std::string &adminName,
120 bool GetAdminItemJsonObject(const Json::Value &admin, const std::string &adminName);
121 bool ParseAdminList(const std::string &adminName, const PolicyItemsMap &itemsMap);
125 …bool SetAdminPolicyItemJsonValue(Json::Value &admin, const std::string &adminName, const std::stri…
128 ErrCode DeleteAdminJsonValue(const std::string &adminName, const std::string &policyName);
129 ErrCode DeleteAdminPolicy(const std::string &adminName, const std::string &policyName);
132 …ErrCode GetAdminPolicy(const std::string &adminName, const std::string &policyName, std::string &p…
[all …]
Diplugin.h49 virtual ErrCode MergePolicyData(const std::string &adminName, std::string &policyData);
50 …virtual void OnHandlePolicyDone(std::uint32_t funcCode, const std::string &adminName, bool isGloba…
51 virtual ErrCode OnAdminRemove(const std::string &adminName, const std::string &policyData) = 0;
52 …virtual void OnAdminRemoveDone(const std::string &adminName, const std::string &currentJsonData) =…
Diplugin_template.h40 ErrCode MergePolicyData(const std::string &adminName, std::string &policyData) override;
42 void OnHandlePolicyDone(std::uint32_t funcCode, const std::string &adminName,
45 … ErrCode OnAdminRemove(const std::string &adminName, const std::string &currentJsonData) override;
47 … void OnAdminRemoveDone(const std::string &adminName, const std::string &removedJsonData) override;
149 typedef ErrCode (CT::*BiAdminFunction)(const std::string &adminName, DT &data);
188 typedef void (CT::*BiAdminConsumer)(const std::string &adminName, DT &data);
465 ErrCode IPluginTemplate<CT, DT>::MergePolicyData(const std::string &adminName, std::string &policyD… in MergePolicyData() argument
475 auto entry = adminValues.find(adminName); in MergePolicyData()
512 …d IPluginTemplate<CT, DT>::OnHandlePolicyDone(std::uint32_t funcCode, const std::string &adminName, in OnHandlePolicyDone() argument
521 ErrCode res = entry->second.handlePolicyDone_(adminName, isGlobalChanged, type); in OnHandlePolicyDone()
[all …]
Denterprise_device_mgr_ability.h68 ErrCode RemoveAdminItem(std::string adminName, std::string policyName, std::string policyValue);
69 ErrCode RemoveAdmin(const std::string &adminName, int32_t userId);
/base/customization/enterprise_device_management/test/unittest/include/
Dplugin_manager_test.h43 ErrCode MergePolicyData(const std::string &adminName, std::string &policyData) override in MergePolicyData() argument
45 return IPlugin::MergePolicyData(adminName, policyData); in MergePolicyData()
48 …void OnHandlePolicyDone(std::uint32_t funcCode, const std::string &adminName, bool isGlobalChanged… in OnHandlePolicyDone() argument
50 ErrCode OnAdminRemove(const std::string &adminName, const std::string &policyData) override in OnAdminRemove() argument
55 void OnAdminRemoveDone(const std::string &adminName, const std::string &policyData) override {} in OnAdminRemoveDone() argument
Diplugin_mock.h38 …void OnHandlePolicyDone(std::uint32_t funcCode, const std::string &adminName, bool isGlobalChanged… in OnHandlePolicyDone() argument
40 ErrCode OnAdminRemove(const std::string &adminName, const std::string &policyData) override in OnAdminRemove() argument
45 …void OnAdminRemoveDone(const std::string &adminName, const std::string &currentJsonData) override … in OnAdminRemoveDone() argument
Diplugin_template_test.h284 ErrCode RemoveAdmin(const std::string &adminName, std::string &data) in RemoveAdmin() argument
317 void RemoveAdminDone(const std::string &adminName, std::string &data) in RemoveAdminDone() argument
/base/customization/enterprise_device_management/test/unittest/src/
Dpolicy_manager_test.cpp63 std::string adminName = TEST_ADMIN_NAME; variable
68 res = PolicyManager::GetInstance()->SetPolicy(adminName, policyName, "false", "true");
72 res = PolicyManager::GetInstance()->GetPolicy(adminName, policyName, policyValue);
81 res = PolicyManager::GetInstance()->GetPolicy(adminName, policyName, policyValue);
97 std::string adminName = TEST_ADMIN_NAME; variable
101 res = PolicyManager::GetInstance()->SetPolicy(adminName, policyName, adminPolicy, mergedPolicy);
105 res = PolicyManager::GetInstance()->GetPolicy(adminName, policyName, policyValue);
115 res = PolicyManager::GetInstance()->GetPolicy(adminName, policyName, policyValue);
Diplugin_template_test.cpp227 std::string adminName; variable
235 adminName = "com.edm.test.demo";
237 plugin->OnHandlePolicyDone(funcCode, adminName, true);
242 plugin->OnHandlePolicyDone(funcCode, adminName, false);
258 std::string adminName; variable
267 adminName = "com.edm.test.demo";
270 plugin->OnAdminRemove(adminName, policyValue);
286 std::string adminName; variable
295 adminName = "com.edm.test.demo";
298 plugin->OnAdminRemoveDone(adminName, policyValue);