• 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 
16 #define MLOG_TAG "NotifyNew"
17 
18 #include "medialibrary_notify_new.h"
19 
20 #include "media_log.h"
21 #include "medialibrary_rdbstore.h"
22 #include "result_set_utils.h"
23 #include "userfilemgr_uri.h"
24 #include "medialibrary_tracer.h"
25 #include "notify_task_worker.h"
26 #include "notification_classification.h"
27 
28 using namespace std;
29 
30 namespace OHOS {
31 namespace Media {
32 namespace Notification {
MediaLibraryNotifyNew()33 MediaLibraryNotifyNew::MediaLibraryNotifyNew() {}
34 
~MediaLibraryNotifyNew()35 MediaLibraryNotifyNew::~MediaLibraryNotifyNew() {}
36 
NotifyInner(NotifyInfoInner notifyInfoInner)37 void MediaLibraryNotifyNew::NotifyInner(NotifyInfoInner notifyInfoInner)
38 {
39     MEDIA_INFO_LOG("NotifyInner");
40 }
41 
UpdateItem(NotifyInfoInner notifyInfoInner)42 void MediaLibraryNotifyNew::UpdateItem(NotifyInfoInner notifyInfoInner)
43 {
44     MEDIA_INFO_LOG("UpdateItem");
45 }
46 
AddItem(NotifyInfoInner notifyInfoInner)47 void MediaLibraryNotifyNew::AddItem(NotifyInfoInner notifyInfoInner)
48 {
49     auto worker = NotifyTaskWorker::GetInstance();
50     worker->AddTaskInfo(notifyInfoInner);
51     if (!worker->IsRunning()) {
52         worker->StartWorker();
53     }
54     MEDIA_INFO_LOG("AddItem");
55 }
56 
DeleteItem(NotifyInfoInner notifyInfoInner)57 void MediaLibraryNotifyNew::DeleteItem(NotifyInfoInner notifyInfoInner)
58 {
59     MEDIA_INFO_LOG("DeleteItem");
60 }
61 
AddAlbum(const std::string & albumId)62 void MediaLibraryNotifyNew::AddAlbum(const std::string &albumId)
63 {
64     NotificationClassification::AddAlbum(albumId);
65 }
66 } // Notification
67 } // Media
68 } // OHOS