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 #include "ime_enabled_info_manager.h"
17
18 #include <algorithm>
19 #include <chrono>
20 #include <iomanip>
21 #include <set>
22 #include <sstream>
23
24 #include "global.h"
25
26 namespace OHOS {
27 namespace MiscServices {
28 using namespace std::chrono;
GetInstance()29 ImeEnabledInfoManager &ImeEnabledInfoManager::GetInstance()
30 {
31 static ImeEnabledInfoManager instance;
32 return instance;
33 }
34
~ImeEnabledInfoManager()35 ImeEnabledInfoManager::~ImeEnabledInfoManager()
36 {
37 }
38
SetCurrentImeStatusChangedHandler(CurrentImeStatusChangedHandler handler)39 void ImeEnabledInfoManager::SetCurrentImeStatusChangedHandler(CurrentImeStatusChangedHandler handler)
40 {
41 }
42
SetEventHandler(const std::shared_ptr<AppExecFwk::EventHandler> & eventHandler)43 void ImeEnabledInfoManager::SetEventHandler(const std::shared_ptr<AppExecFwk::EventHandler> &eventHandler)
44 {
45 }
46
RegularInit(const std::map<int32_t,std::vector<FullImeInfo>> & fullImeInfos)47 int32_t ImeEnabledInfoManager::RegularInit(const std::map<int32_t, std::vector<FullImeInfo>> &fullImeInfos)
48 {
49 return ErrorCode::NO_ERROR;
50 }
51
Init(const std::map<int32_t,std::vector<FullImeInfo>> & fullImeInfos)52 int32_t ImeEnabledInfoManager::Init(const std::map<int32_t, std::vector<FullImeInfo>> &fullImeInfos)
53 {
54 return ErrorCode::NO_ERROR;
55 }
56
Delete(int32_t userId)57 int32_t ImeEnabledInfoManager::Delete(int32_t userId)
58 {
59 return ErrorCode::NO_ERROR;
60 }
61
Switch(int32_t userId,const std::vector<FullImeInfo> & imeInfos)62 int32_t ImeEnabledInfoManager::Switch(int32_t userId, const std::vector<FullImeInfo> &imeInfos)
63 {
64 return ErrorCode::NO_ERROR;
65 }
Add(int32_t userId,const FullImeInfo & imeInfo)66 int32_t ImeEnabledInfoManager::Add(int32_t userId, const FullImeInfo &imeInfo)
67 {
68 return ErrorCode::NO_ERROR;
69 }
70
Delete(int32_t userId,const std::string & bundleName)71 int32_t ImeEnabledInfoManager::Delete(int32_t userId, const std::string &bundleName)
72 {
73 return ErrorCode::NO_ERROR;
74 }
75
Update(int32_t userId,const std::string & bundleName,const std::string & extensionName,EnabledStatus status)76 int32_t ImeEnabledInfoManager::Update(
77 int32_t userId, const std::string &bundleName, const std::string &extensionName, EnabledStatus status)
78 {
79 return ErrorCode::NO_ERROR;
80 }
81
GetEnabledState(int32_t userId,const std::string & bundleName,EnabledStatus & status)82 int32_t ImeEnabledInfoManager::GetEnabledState(int32_t userId, const std::string &bundleName, EnabledStatus &status)
83 {
84 return ErrorCode::NO_ERROR;
85 }
86
GetEnabledStates(int32_t userId,std::vector<Property> & props)87 int32_t ImeEnabledInfoManager::GetEnabledStates(int32_t userId, std::vector<Property> &props)
88 {
89 return ErrorCode::NO_ERROR;
90 }
91
IsDefaultFullMode(int32_t userId,const std::string & bundleName)92 bool ImeEnabledInfoManager::IsDefaultFullMode(int32_t userId, const std::string &bundleName)
93 {
94 return true;
95 }
96
OnFullExperienceTableChanged(int32_t userId)97 void ImeEnabledInfoManager::OnFullExperienceTableChanged(int32_t userId)
98 {
99 }
100 } // namespace MiscServices
101 } // namespace OHOS