• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2024 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 
16 #include "module_ipc/svc_backup_connection.h"
17 
18 #include "svc_backup_connection_mock.h"
19 
20 namespace OHOS::FileManagement::Backup {
21 using namespace std;
22 
OnAbilityConnectDone(const AppExecFwk::ElementName &,const sptr<IRemoteObject> &,int)23 void SvcBackupConnection::OnAbilityConnectDone(const AppExecFwk::ElementName&, const sptr<IRemoteObject>&, int) {}
24 
OnAbilityDisconnectDone(const AppExecFwk::ElementName &,int)25 void SvcBackupConnection::OnAbilityDisconnectDone(const AppExecFwk::ElementName&, int) {}
26 
ConnectBackupExtAbility(AAFwk::Want & want,int32_t userId,bool isCleanCalled)27 ErrCode SvcBackupConnection::ConnectBackupExtAbility(AAFwk::Want &want, int32_t userId, bool isCleanCalled)
28 {
29     return BSvcBackupConnection::connect->ConnectBackupExtAbility(want, userId, isCleanCalled);
30 }
31 
DisconnectBackupExtAbility()32 ErrCode SvcBackupConnection::DisconnectBackupExtAbility()
33 {
34     return BSvcBackupConnection::connect->DisconnectBackupExtAbility();
35 }
36 
IsExtAbilityConnected()37 bool SvcBackupConnection::IsExtAbilityConnected()
38 {
39     return BSvcBackupConnection::connect->IsExtAbilityConnected();
40 }
41 
SetCallback(function<void (const std::string &&)>)42 void SvcBackupConnection::SetCallback(function<void(const std::string &&)>) {}
43 
SetCallDied(function<void (const std::string &&,bool)>)44 void SvcBackupConnection::SetCallDied(function<void(const std::string &&, bool)>) {}
45 
GetBackupExtProxy()46 sptr<IExtension> SvcBackupConnection::GetBackupExtProxy()
47 {
48     return BSvcBackupConnection::connect->GetBackupExtProxy();
49 }
50 
WaitDisconnectDone()51 bool SvcBackupConnection::WaitDisconnectDone()
52 {
53     return BSvcBackupConnection::connect->WaitDisconnectDone();
54 }
55 } // namespace OHOS::FileManagement::Backup