Home
last modified time | relevance | path

Searched refs:errCode (Results 1 – 25 of 295) sorted by relevance

12345678910>>...12

/base/telephony/call_manager/services/telephony_interaction/src/
Dcellular_call_connection.cpp186 int errCode = cellularCallInterfacePtr_->Dial(callInfo); in Dial() local
187 if (errCode != TELEPHONY_SUCCESS) { in Dial()
188 TELEPHONY_LOGE("dial failed, errcode:%{public}d", errCode); in Dial()
189 return errCode; in Dial()
202 int errCode = cellularCallInterfacePtr_->HangUp(callInfo, type); in HangUp() local
203 if (errCode != TELEPHONY_SUCCESS) { in HangUp()
204 TELEPHONY_LOGE("hangup call failed, errcode:%{public}d", errCode); in HangUp()
205 return errCode; in HangUp()
218 int errCode = cellularCallInterfacePtr_->Reject(callInfo); in Reject() local
219 if (errCode != TELEPHONY_SUCCESS) { in Reject()
[all …]
/base/account/os_account/frameworks/common/account_error/src/
Daccount_error_no.cpp19 int32_t AppAccountConvertOtherJSErrCode(int32_t errCode) in AppAccountConvertOtherJSErrCode() argument
21 switch (errCode) { in AppAccountConvertOtherJSErrCode()
58 int32_t AppAccountConvertToJSErrCode(int32_t errCode) in AppAccountConvertToJSErrCode() argument
60 if (errCode == ERR_ACCOUNT_COMMON_PERMISSION_DENIED) { in AppAccountConvertToJSErrCode()
62 } else if (errCode == ERR_APPACCOUNT_SERVICE_GET_BUNDLE_NAME || in AppAccountConvertToJSErrCode()
63 errCode == ERR_APPACCOUNT_SERVICE_GET_BUNDLE_INFO || in AppAccountConvertToJSErrCode()
64 errCode == ERR_APPACCOUNT_SERVICE_DISABLE_APP_ACCESS_NOT_EXISTED) { in AppAccountConvertToJSErrCode()
66 } else if (errCode == ERR_APPACCOUNT_SERVICE_OAUTH_SERVICE_EXCEPTION) { in AppAccountConvertToJSErrCode()
69 return AppAccountConvertOtherJSErrCode(errCode); in AppAccountConvertToJSErrCode()
73 int32_t OsAccountConvertToJSErrCode(int32_t errCode) in OsAccountConvertToJSErrCode() argument
[all …]
/base/account/os_account/frameworks/test/unittest/
Daccount_osaccount_proxy_mock_test.cpp87 …ErrCode errCode = OsAccountManager::CreateOsAccount(STRING_TEST_NAME, OsAccountType::ADMIN, osAcco… variable
88 ASSERT_EQ(ERR_ACCOUNT_COMMON_GET_SYSTEM_ABILITY_MANAGER, errCode);
103 ErrCode errCode = OsAccountManager::CreateOsAccountForDomain(type, domainInfo, osAccountInfo); variable
104 ASSERT_EQ(ERR_ACCOUNT_COMMON_GET_SYSTEM_ABILITY_MANAGER, errCode);
116 ErrCode errCode = OsAccountManager::OsAccountManager::RemoveOsAccount(TEST_USER_ID); variable
117 ASSERT_EQ(ERR_ACCOUNT_COMMON_GET_SYSTEM_ABILITY_MANAGER, errCode);
129 ErrCode errCode = OsAccountManager::IsOsAccountExists(TEST_USER_ID, isOsAccountExists); variable
130 ASSERT_EQ(ERR_ACCOUNT_COMMON_GET_SYSTEM_ABILITY_MANAGER, errCode);
143 ErrCode errCode = OsAccountManager::IsOsAccountActived(TEST_USER_ID, isOsAccountActived); variable
144 ASSERT_EQ(ERR_ACCOUNT_COMMON_GET_SYSTEM_ABILITY_MANAGER, errCode);
[all …]
/base/telephony/call_manager/frameworks/native/src/
Dcall_manager_proxy.cpp304 int32_t errCode = callManagerServicePtr_->DialCall(number, extras); in DialCall() local
305 if (errCode != TELEPHONY_SUCCESS) { in DialCall()
306 TELEPHONY_LOGE("DialCall failed, errcode:%{public}d", errCode); in DialCall()
307 return errCode; in DialCall()
319 int32_t errCode = callManagerServicePtr_->AnswerCall(callId, videoState); in AnswerCall() local
320 if (errCode != TELEPHONY_SUCCESS) { in AnswerCall()
321 TELEPHONY_LOGE("AnswerCall failed, errcode:%{public}d", errCode); in AnswerCall()
322 return errCode; in AnswerCall()
334 int32_t errCode = callManagerServicePtr_->RejectCall(callId, isSendSms, content); in RejectCall() local
335 if (errCode != TELEPHONY_SUCCESS) { in RejectCall()
[all …]
/base/account/os_account/services/accountmgr/src/osaccount/
Dinner_os_account_manager.cpp93 ErrCode errCode = osAccountControl_->GetConstraintsByType(OsAccountType::ADMIN, constants); in CreateBaseStandardAccount() local
94 if (errCode != ERR_OK) { in CreateBaseStandardAccount()
95 ACCOUNT_LOGE("find first standard type err, errCode %{public}d.", errCode); in CreateBaseStandardAccount()
113 ErrCode errCode = osAccountControl_->GetOsAccountInfoById(defaultActivatedId_, osAccountInfo); in StartAccount() local
114 if (errCode != ERR_OK) { in StartAccount()
116 … ACCOUNT_LOGE("Init start base account failed. cannot find account, errCode %{public}d.", errCode); in StartAccount()
120 defaultActivatedId_, errCode); in StartAccount()
121 errCode = osAccountControl_->GetOsAccountInfoById(Constants::START_USER_ID, osAccountInfo); in StartAccount()
122 if (errCode != ERR_OK) { in StartAccount()
123 … ACCOUNT_LOGE("Restart base account failed. cannot find account, errCode %{public}d.", errCode); in StartAccount()
[all …]
Dos_account_domain_account_callback.cpp35 void CheckAndCreateDomainAccountCallback::OnResult(int32_t errCode, Parcel &parcel) in OnResult() argument
44 if (errCode != ERR_OK) { in OnResult()
46 return innerCallback_->OnResult(errCode, resultParcel); in OnResult()
61errCode = IInnerOsAccountManager::GetInstance().BindDomainAccount(type_, domainAccountInfo, innerC… in OnResult()
62 if (errCode != ERR_OK) { in OnResult()
63 return innerCallback_->OnResult(errCode, resultParcel); in OnResult()
72 void BindDomainAccountCallback::OnResult(int32_t errCode, Parcel &parcel) in OnResult() argument
84 if (errCode != ERR_OK) { in OnResult()
89 return innerCallback_->OnResult(errCode, parcel); in OnResult()
93 errCode = IInnerOsAccountManager::GetInstance().SendMsgForAccountCreate(osAccountInfo_); in OnResult()
[all …]
Dos_account_database_operator.cpp69 ErrCode errCode = ERR_OK; in GetOsAccountListFromDatabase() local
71 errCode = accountDataStorage_->LoadAllData(osAccountMapInfos); in GetOsAccountListFromDatabase()
79 errCode = storagePtr->LoadAllData(osAccountMapInfos); in GetOsAccountListFromDatabase()
82 if (errCode != ERR_OK) { in GetOsAccountListFromDatabase()
84 return errCode; in GetOsAccountListFromDatabase()
108 ErrCode errCode = accountDataStorage_->AddAccountInfo(osAccountInfo); in InsertOsAccountIntoDataBase() local
109 if (errCode != ERR_OK) { in InsertOsAccountIntoDataBase()
111 errCode, osAccountInfo.GetLocalId()); in InsertOsAccountIntoDataBase()
124 ErrCode errCode = accountDataStorage_->RemoveValueFromKvStore(std::to_string(id)); in DelOsAccountFromDatabase() local
125 if (errCode != ERR_OK) { in DelOsAccountFromDatabase()
[all …]
/base/account/os_account/services/accountmgr/test/unittest/ohos_account/
Dohos_account_data_deal_test.cpp71 ErrCode errCode = dataDeal.AccountInfoFromJson(accountInfo, TEST_VALID_USER_ID); variable
72 EXPECT_EQ(errCode, ERR_ACCOUNT_DATADEAL_NOT_READY);
85 ErrCode errCode = dataDeal.Init(TEST_VALID_USER_ID); variable
86 EXPECT_EQ(errCode, ERR_OK);
88 errCode = dataDeal.AccountInfoFromJson(accountInfo, TEST_VALID_USER_ID);
89 EXPECT_EQ(errCode, ERR_OK);
109 ErrCode errCode = dataDeal.Init(TEST_VALID_USER_ID); variable
110 EXPECT_EQ(errCode, ERR_OK);
115 errCode = dataDeal.AccountInfoFromJson(accountInfo, TEST_VALID_USER_ID);
116 EXPECT_EQ(errCode, ERR_OK);
[all …]
/base/usb/usb_manager/utils/native/include/
Dusb_napi_errors.h39 void ThrowBusinessError(const napi_env &env, int32_t errCode, const std::string &errMsg);
40 napi_value CreateBusinessError(const napi_env &env, int32_t errCode, const std::string &errMsg);
42 #define USB_ASSERT_BASE(env, assertion, errCode, errMsg, retVal) \ argument
46 ThrowBusinessError((env), errCode, errMsg); \
52 #define USB_ASSERT(env, assertion, errCode, errMsg) USB_ASSERT_BASE(env, assertion, errCode, errMsg… argument
53 #define USB_ASSERT_RETURN_VOID(env, assertion, errCode, errMsg) \ argument
54 USB_ASSERT_BASE(env, assertion, errCode, errMsg, NOTHING)
55 #define USB_ASSERT_RETURN_FALSE(env, assertion, errCode, errMsg) USB_ASSERT_BASE(env, assertion, er… argument
56 #define USB_ASSERT_RETURN_UNDEF(env, assertion, errCode, errMsg) \ argument
60 USB_ASSERT_BASE(env, assertion, errCode, errMsg, obj); \
/base/notification/distributed_notification_service/test/bechmarktest/notification_services_test/
Dnotification_service_test.cpp132 ErrCode errCode = advancedNotificationService_->AddSlots(slots); in BENCHMARK_F() local
133 if (errCode != ERR_OK) { in BENCHMARK_F()
151 ErrCode errCode = advancedNotificationService_->AddSlots(slots); in BENCHMARK_F() local
152 if (errCode != ERR_OK) { in BENCHMARK_F()
156errCode = advancedNotificationService_->RemoveSlotByType(NotificationConstant::SlotType::CUSTOM); in BENCHMARK_F()
157 if (errCode != ERR_OK) { in BENCHMARK_F()
174 ErrCode errCode = advancedNotificationService_->Subscribe(subscriber->GetImpl(), info); in BENCHMARK_F() local
175 if (errCode != ERR_OK) { in BENCHMARK_F()
205 ErrCode errCode = advancedNotificationService_->Publish(label, req); in BENCHMARK_F() local
206 if (errCode != ERR_OK) { in BENCHMARK_F()
[all …]
/base/account/os_account/dfx/hisysevent_adapter/
Dhisysevent_adapter.cpp29 void ReportServiceStartFail(int32_t errCode, const std::string& errMsg) in ReportServiceStartFail() argument
34 "ERROR_TYPE", errCode, in ReportServiceStartFail()
37 ACCOUNT_LOGE("hisysevent write failed! ret %{public}d. errCode %{public}d", ret, errCode); in ReportServiceStartFail()
40 (void)errCode; in ReportServiceStartFail()
64 int32_t id, const std::string& operationStr, int32_t errCode, const std::string& errMsg) in ReportOsAccountOperationFail() argument
71 "ERROR_TYPE", errCode, in ReportOsAccountOperationFail()
75 ret, id, operationStr.c_str(), errCode, errMsg.c_str()); in ReportOsAccountOperationFail()
79 (void)errCode; in ReportOsAccountOperationFail()
86 int32_t userId, const std::string& operationStr, int32_t errCode, const std::string& errMsg) in ReportOhosAccountOperationFail() argument
93 "ERROR_TYPE", errCode, in ReportOhosAccountOperationFail()
[all …]
/base/account/os_account/services/accountmgr/test/unittest/account_iam/
Daccount_iam_callback_test.cpp140 int32_t errCode = 0; variable
141 userAuthCallback->OnResult(errCode, extraInfo);
143 errCode = 10; // result != 0
144 userAuthCallback->OnResult(errCode, extraInfo);
145 EXPECT_EQ(errCode, callback->result_);
161 int32_t errCode = 0; variable
162 userAuthCallback->OnResult(errCode, extraInfo);
163 EXPECT_EQ(errCode, callback->result_);
164 errCode = 10; // result != 0 && authType_ != AuthType::PIN
165 userAuthCallback->OnResult(errCode, extraInfo);
[all …]
/base/usb/usb_manager/utils/native/src/
Dusb_napi_errors.cpp24 std::optional<std::string_view> GetErrMsgByErrCode(int32_t errCode) in GetErrMsgByErrCode() argument
26 auto obj = ERRCODE_MSG_MAP.find(errCode); in GetErrMsgByErrCode()
28 USB_HILOGE(MODULE_JS_NAPI, "invalid errCode %{public}d", errCode); in GetErrMsgByErrCode()
34 napi_value CreateBusinessError(const napi_env &env, int32_t errCode, const std::string &errMsg) in CreateBusinessError() argument
36 auto commMsg = GetErrMsgByErrCode(errCode); in CreateBusinessError()
48 NAPI_CALL(env, napi_create_int32(env, errCode, &code)); in CreateBusinessError()
56 void ThrowBusinessError(const napi_env &env, int32_t errCode, const std::string &errMsg) in ThrowBusinessError() argument
59 businessError = CreateBusinessError(env, errCode, errMsg); in ThrowBusinessError()
/base/msdp/device_status/frameworks/js/napi/interaction/coordination/src/
Djs_coordination_manager.cpp37 int32_t errCode = INTERACTION_MGR->PrepareCoordination(callback); in Prepare() local
38 if (errCode != RET_OK) { in Prepare()
41 HandleExecuteResult(env, errCode); in Prepare()
52 int32_t errCode = INTERACTION_MGR->UnprepareCoordination(callback); in Unprepare() local
53 if (errCode != RET_OK) { in Unprepare()
56 HandleExecuteResult(env, errCode); in Unprepare()
68 … int32_t errCode = INTERACTION_MGR->ActivateCoordination(remoteNetworkId, startDeviceId, callback); in Activate() local
69 if (errCode != RET_OK) { in Activate()
72 HandleExecuteResult(env, errCode); in Activate()
83 int32_t errCode = INTERACTION_MGR->DeactivateCoordination(isUnchained, callback); in Deactivate() local
[all …]
/base/time/time_service/test/unittest/service_test/src/
Dtime_client_test.cpp262 auto errCode = TimeServiceClient::GetInstance()->GetWallTimeMs(time); variable
263 EXPECT_TRUE(errCode == TimeError::E_TIME_OK);
274 auto errCode = TimeServiceClient::GetInstance()->GetWallTimeNs(time); variable
275 EXPECT_TRUE(errCode == TimeError::E_TIME_OK);
286 auto errCode = TimeServiceClient::GetInstance()->GetBootTimeNs(time); variable
287 EXPECT_TRUE(errCode == TimeError::E_TIME_OK);
298 auto errCode = TimeServiceClient::GetInstance()->GetBootTimeMs(time); variable
299 EXPECT_TRUE(errCode == TimeError::E_TIME_OK);
310 auto errCode = TimeServiceClient::GetInstance()->GetMonotonicTimeMs(time); variable
311 EXPECT_TRUE(errCode == TimeError::E_TIME_OK);
[all …]
/base/msdp/device_status/frameworks/js/napi/interaction/cooperate/src/
Djs_cooperate_manager.cpp37 int32_t errCode = 0; in Enable() local
39 errCode = INTERACTION_MGR->PrepareCoordination(callback); in Enable()
41 errCode = INTERACTION_MGR->UnprepareCoordination(callback); in Enable()
43 if (errCode != RET_OK) { in Enable()
46 HandleExecuteResult(env, errCode); in Enable()
58 …int32_t errCode = INTERACTION_MGR->ActivateCoordination(remoteNetworkDescriptor, startDeviceId, ca… in Start() local
59 if (errCode != RET_OK) { in Start()
62 HandleExecuteResult(env, errCode); in Start()
74 int32_t errCode = INTERACTION_MGR->DeactivateCoordination(isUnchained, callback); in Stop() local
75 if (errCode != RET_OK) { in Stop()
[all …]
/base/telephony/call_manager/services/call_manager_service/include/
Dcall_manager_hisysevent.h40 const int32_t errCode, const std::string &desc);
42 const int32_t errCode, const std::string &desc);
44 const int32_t errCode, const std::string &desc);
46 const int32_t slotId, const int32_t callId, const int32_t errCode, const std::string &desc);
47 void GetErrorDescription(const int32_t errCode, std::string &errordesc);
56 static int32_t ErrorCodeConversion(const int32_t errCode, CallErrorCode &eventValue);
57 static int32_t CallDataErrorCodeConversion(const int32_t errCode, CallErrorCode &eventValue);
58 … static int32_t CallInterfaceErrorCodeConversion(const int32_t errCode, CallErrorCode &eventValue);
59 static int32_t TelephonyErrorCodeConversion(const int32_t errCode, CallErrorCode &eventValue);
/base/account/os_account/services/accountmgr/test/unittest/os_account/
Dos_account_inner_account_mgr_cov.cpp217 …int errCode = innerMgrService_->CreateOsAccount(ACCOUNT_NAME, OsAccountType::NORMAL, osAccountInfo… variable
219 ASSERT_EQ(errCode, ERR_OK);
221 errCode = innerMgrService_->SetOsAccountName(localID, ACCOUNT_SET_NAME);
222 ASSERT_EQ(errCode, ERR_OK);
226 errCode = innerMgrService_->SetOsAccountName(localID, ACCOUNT_SET_NAME);
227 ASSERT_EQ(errCode, ERR_OK);
229 errCode = innerMgrService_->RemoveOsAccount(localID);
230 ASSERT_EQ(errCode, ERR_OK);
255 …int errCode = innerMgrService_->CreateOsAccount(ACCOUNT_NAME, OsAccountType::NORMAL, osAccountInfo… variable
257 ASSERT_EQ(errCode, ERR_OK);
[all …]
/base/msdp/device_status/frameworks/js/napi/src/
Ddevicestatus_napi_error.cpp29 napi_value CreateNapiError(const napi_env &env, int32_t errCode, const std::string &errMessage) in CreateNapiError() argument
34 NAPI_CALL(env, napi_create_int32(env, errCode, &code)); in CreateNapiError()
51 void ThrowErr(const napi_env &env, int32_t errCode, const std::string &printMsg) in ThrowErr() argument
53 FI_HILOGE("Message:%{public}s, code:%{public}d", printMsg.c_str(), errCode); in ThrowErr()
54 std::optional<std::string> msg = GetErrMsg(errCode); in ThrowErr()
56 FI_HILOGE("ErrCode:%{public}d is invalid", errCode); in ThrowErr()
59 napi_value error = CreateNapiError(env, errCode, msg.value()); in ThrowErr()
/base/account/os_account/frameworks/domain_account/src/
Ddomain_account_plugin_service.cpp100 ErrCode errCode = CheckAndInitExecEnv(callback, &callbackClient); in IsAccountTokenValid() local
101 if (errCode != ERR_OK) { in IsAccountTokenValid()
102 return errCode; in IsAccountTokenValid()
114 ErrCode errCode = CheckAndInitExecEnv(callback, &callbackClient); in GetAccessToken() local
115 if (errCode != ERR_OK) { in GetAccessToken()
116 return errCode; in GetAccessToken()
143 ErrCode errCode = CheckAndInitExecEnv(callback, &callbackClient); in GetDomainAccountInfo() local
144 if (errCode != ERR_OK) { in GetDomainAccountInfo()
145 return errCode; in GetDomainAccountInfo()
156 ErrCode errCode = CheckAndInitExecEnv(callback, &callbackClient); in OnAccountBound() local
[all …]
/base/telephony/call_manager/services/call_manager_service/src/
Dcall_manager_hisysevent.cpp72 const int32_t videoState, const int32_t errCode, const std::string &desc) in WriteIncomingCallFaultEvent() argument
75 if (ErrorCodeConversion(errCode, value)) { in WriteIncomingCallFaultEvent()
81 …CALL_TYPE_KEY, callType, VIDEO_STATE_KEY, videoState, ERROR_TYPE_KEY, errCode, ERROR_MSG_KEY, desc… in WriteIncomingCallFaultEvent()
86 const int32_t videoState, const int32_t errCode, const std::string &desc) in WriteDialCallFaultEvent() argument
89 if (ErrorCodeConversion(errCode, value)) { in WriteDialCallFaultEvent()
95 …CALL_TYPE_KEY, callType, VIDEO_STATE_KEY, videoState, ERROR_TYPE_KEY, errCode, ERROR_MSG_KEY, desc… in WriteDialCallFaultEvent()
100 const int32_t videoState, const int32_t errCode, const std::string &desc) in WriteAnswerCallFaultEvent() argument
103 if (ErrorCodeConversion(errCode, value)) { in WriteAnswerCallFaultEvent()
109 … CALL_ID_KEY, callId, VIDEO_STATE_KEY, videoState, ERROR_TYPE_KEY, errCode, ERROR_MSG_KEY, desc); in WriteAnswerCallFaultEvent()
114 const int32_t slotId, const int32_t callId, const int32_t errCode, const std::string &desc) in WriteHangUpFaultEvent() argument
[all …]
/base/sensors/miscdevice/interfaces/plugin/vibrator/src/
Dvibrator_napi_error.cpp25 napi_value CreateBusinessError(const napi_env &env, const int32_t errCode, const std::string &errMe… in CreateBusinessError() argument
30 NAPI_CALL(env, napi_create_int32(env, errCode, &code)); in CreateBusinessError()
46 void ThrowErr(const napi_env &env, const int32_t errCode, const std::string &printMsg) in ThrowErr() argument
48 MISC_HILOGE("Message:%{public}s, code:%{public}d", printMsg.c_str(), errCode); in ThrowErr()
49 auto msg = GetNapiError(errCode); in ThrowErr()
51 MISC_HILOGE("ErrCode:%{public}d is invalid", errCode); in ThrowErr()
56 napi_value error = CreateBusinessError(env, errCode, msg.value()); in ThrowErr()
/base/sensors/sensor/interfaces/plugin/src/
Dsensor_napi_error.cpp25 napi_value CreateBusinessError(const napi_env &env, const int32_t errCode, const std::string &errMe… in CreateBusinessError() argument
30 NAPI_CALL(env, napi_create_int32(env, errCode, &code)); in CreateBusinessError()
46 void ThrowErr(const napi_env &env, const int32_t errCode, const std::string &printMsg) in ThrowErr() argument
48 SEN_HILOGE("Message:%{public}s, code:%{public}d", printMsg.c_str(), errCode); in ThrowErr()
49 auto msg = GetNapiError(errCode); in ThrowErr()
51 SEN_HILOGE("ErrCode:%{public}d is invalid", errCode); in ThrowErr()
56 napi_value error = CreateBusinessError(env, errCode, msg.value()); in ThrowErr()
/base/location/frameworks/js/napi/source/
Dlocation_napi_errcode.cpp23 void HandleSyncErrCode(const napi_env &env, int32_t errCode) in HandleSyncErrCode() argument
25 LBSLOGI(LOCATOR_STANDARD, "HandleSyncErrCode, errCode = %{public}d", errCode); in HandleSyncErrCode()
26 std::string errMsg = GetErrorMsgByCode(errCode); in HandleSyncErrCode()
28 napi_throw_error(env, std::to_string(errCode).c_str(), errMsg.c_str()); in HandleSyncErrCode()
/base/location/frameworks/native/source/
Dlocator_impl.cpp116 LocationErrCode errCode = proxy->EnableAbilityV9(enable); in EnableAbility() local
118 if (errCode == ERRCODE_SUCCESS) { in EnableAbility()
630 LocationErrCode errCode = locationDataManager_->QuerySwitchState(isEnabled); in IsLocationEnabledV9() local
631 return errCode; in IsLocationEnabledV9()
645 LocationErrCode errCode = proxy->EnableAbilityV9(enable); in EnableAbilityV9() local
647 if (errCode == ERRCODE_SUCCESS) { in EnableAbilityV9()
652 return errCode; in EnableAbilityV9()
667 LocationErrCode errCode = proxy->StartLocatingV9(requestConfig, callback); in StartLocatingV9() local
668 return errCode; in StartLocatingV9()
682 LocationErrCode errCode = proxy->StopLocatingV9(callback); in StopLocatingV9() local
[all …]

12345678910>>...12