• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (C) 2025 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 #define MLOG_TAG "Media_IPC"
16 
17 #include "media_controller_service_factory.h"
18 
19 #include "cloud_media_data_controller_service.h"
20 #include "cloud_media_album_controller_service.h"
21 #include "cloud_media_photo_controller_service.h"
22 #include "cloud_media_download_controller_service.h"
23 #include "media_assets_controller_service.h"
24 #include "media_albums_controller_service.h"
25 #include "media_refresh_controller_service.h"
26 
27 namespace OHOS::Media::IPC {
MediaControllerServiceFactory()28 MediaControllerServiceFactory::MediaControllerServiceFactory()
29 {
30     this->controllerServices_ = {
31         std::make_shared<CloudSync::CloudMediaDataControllerService>(),
32         std::make_shared<CloudSync::CloudMediaAlbumControllerService>(),
33         std::make_shared<CloudSync::CloudMediaPhotoControllerService>(),
34         std::make_shared<CloudSync::CloudMediaDownloadControllerService>(),
35         std::make_shared<MediaAssetsControllerService>(),
36         std::make_shared<MediaAlbumsControllerService>(),
37         std::make_shared<MediaRefreshControllerService>(),
38     };
39 }
40 
GetAllMediaControllerService()41 std::vector<std::shared_ptr<IMediaControllerService>> MediaControllerServiceFactory::GetAllMediaControllerService()
42 {
43     return this->controllerServices_;
44 }
45 }  // namespace OHOS::Media::IPC