1 /*
2  * Copyright (c) 2022-2023 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 "b_tarball/b_tarball_cmdline.h"
17 
18 #include <sstream>
19 #include <string_view>
20 
21 #include <unistd.h>
22 
23 #include <gmock/gmock.h>
24 #include <gtest/gtest.h>
25 
26 namespace OHOS::FileManagement::Backup {
27 using namespace std;
28 
Tar(string_view root,vector<string_view> includes,vector<string_view> excludes)29 void BTarballCmdline::Tar(string_view root, vector<string_view> includes, vector<string_view> excludes)
30 {
31     GTEST_LOG_(INFO) << "BTarballCmdline Tar " << root;
32 }
33 
Untar(string_view root)34 void BTarballCmdline::Untar(string_view root)
35 {
36     GTEST_LOG_(INFO) << "BTarballCmdline Untar " << root;
37 }
38 
BTarballCmdline(string_view tarballDir,string_view tarballName)39 BTarballCmdline::BTarballCmdline(string_view tarballDir, string_view tarballName)
40     : tarballDir_(tarballDir), tarballName_(tarballName)
41 {
42     tarballPath_ = tarballDir_ + "/" + tarballName_;
43 }
44 } // namespace OHOS::FileManagement::Backup
45