1 /*
2 * Copyright (c) 2021-2022 Huawei Device Co., Ltd.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15 #include "os_account_delete_user_idm_callback.h"
16 #include "account_error_no.h"
17 #include "account_log_wrapper.h"
18 #include "os_account_manager.h"
19
20 namespace OHOS {
21 namespace AccountSA {
22 #ifdef HAS_USER_AUTH_PART
OnResult(int32_t result,const UserIam::UserAuth::Attributes & extraInfo)23 void OsAccountDeleteUserIdmCallback::OnResult(int32_t result, const UserIam::UserAuth::Attributes &extraInfo)
24 {
25 std::unique_lock<std::mutex> lock(mutex_);
26 ACCOUNT_LOGI("IAM OnResult callback! result %{public}d", result);
27 isIdmOnResultCallBack_ = true;
28 resultCode_ = result;
29 onResultCondition_.notify_one();
30 }
31
OnAcquireInfo(int32_t module,uint32_t acquireInfo,const UserIam::UserAuth::Attributes & extraInfo)32 void OsAccountDeleteUserIdmCallback::OnAcquireInfo(int32_t module, uint32_t acquireInfo,
33 const UserIam::UserAuth::Attributes &extraInfo)
34 {
35 ACCOUNT_LOGI("IAM OnAcquireInfo callback! module %{public}d, acquire %{public}u.", module, acquireInfo);
36 }
37 #endif // HAS_USER_AUTH_PART
38 } // namespace AccountSA
39 } // namespace OHOS