• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 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 "dk_assets_downloader.h"
17 #include "dk_database.h"
18 
19 namespace DriveKit {
DownLoadAssets(std::shared_ptr<DKContext> context,std::vector<DKDownloadAsset> & assetsToDownload,DKAssetPath downLoadPath,DKDownloadId & id,std::function<void (std::shared_ptr<DKContext>,std::shared_ptr<const DKDatabase>,const std::map<DKDownloadAsset,DKDownloadResult> &,const DKError &)> resultCallback,std::function<void (std::shared_ptr<DKContext>,DKDownloadAsset,TotalSize,DownloadSize)> progressCallback)20 DKLocalErrorCode DKAssetsDownloader::DownLoadAssets(
21     std::shared_ptr<DKContext> context,
22     std::vector<DKDownloadAsset> &assetsToDownload,
23     DKAssetPath downLoadPath,
24     DKDownloadId &id,
25     std::function<void(std::shared_ptr<DKContext>,
26                        std::shared_ptr<const DKDatabase>,
27                        const std::map<DKDownloadAsset, DKDownloadResult> &,
28                        const DKError &)> resultCallback,
29     std::function<void(std::shared_ptr<DKContext>, DKDownloadAsset, TotalSize, DownloadSize)> progressCallback)
30 {
31     return DKLocalErrorCode::NO_ERROR;
32 }
33 
DownLoadAssets(DKDownloadAsset & assetsToDownload)34 DKLocalErrorCode DKAssetsDownloader::DownLoadAssets(DKDownloadAsset &assetsToDownload)
35 {
36     return DKLocalErrorCode::NO_ERROR;
37 }
38 
CancelDownloadAssets(DKDownloadId id)39 DKLocalErrorCode DKAssetsDownloader::CancelDownloadAssets(DKDownloadId id)
40 {
41     return DKLocalErrorCode::NO_ERROR;
42 }
43 } // namespace DriveKit
44