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 #ifndef NOTIFICATION_ADVANCED_DATASHAER_HELPER_EXT_H
17 #define NOTIFICATION_ADVANCED_DATASHAER_HELPER_EXT_H
18 
19 #include "datashare_helper.h"
20 #include "iremote_broker.h"
21 #include "singleton.h"
22 #include "system_ability_definition.h"
23 #include "uri.h"
24 
25 namespace OHOS {
26 namespace Notification {
27 namespace {
28 constexpr const char *KEY_FOCUS_MODE_ENABLE_EXT = "focus_mode_enable";
29 constexpr const char *KEY_FOCUS_MODE_PROFILE_EXT = "focus_mode_profile";
30 constexpr const char *KEY_FOCUS_MODE_CALL_MESSAGE_POLICY_EXT = "focus_mode_call_message_policy";
31 } // namespace
32 
33 class AdvancedDatashareHelperExt : DelayedSingleton<AdvancedDatashareHelperExt> {
34 public:
35     AdvancedDatashareHelperExt();
36     ~AdvancedDatashareHelperExt() = default;
37     bool Query(Uri &uri, const std::string &key, std::string &value);
38     std::string GetUnifiedGroupEnableUri() const;
39 
40 private:
41     std::shared_ptr<DataShare::DataShareHelper> CreateDataShareHelper();
42 };
43 } // namespace Notification
44 } // namespace OHOS
45 #endif // NOTIFICATION_ADVANCED_DATASHAER_HELPER_EXT_H
46