• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 #ifndef SERVICE_MANAGER_TYPE_H
16 #define SERVICE_MANAGER_TYPE_H
17 
18 #ifdef TRIGGER_ENABLE
19 #include "trigger_manager.h"
20 #else
21 #include "dummy_trigger_manager.h"
22 #endif
23 
24 #ifdef ENGINE_ENABLE
25 #include "intell_voice_engine_manager.h"
26 #elif defined(FIRST_STAGE_ONESHOT_ENABLE)
27 #include "only_first_engine_manager.h"
28 #else
29 #include "dummy_engine_manager.h"
30 #endif
31 
32 #include "ffrt_api.h"
33 
34 namespace OHOS {
35 namespace IntellVoiceEngine {
36 template<typename T, typename E>
37 class IntellVoiceServiceManager;
38 #ifdef TRIGGER_ENABLE
39 using TriggerManagerType = OHOS::IntellVoiceTrigger::TriggerManager;
40 #else
41 using TriggerManagerType = OHOS::IntellVoiceTrigger::DummyTriggerManager;
42 #endif
43 #ifdef ENGINE_ENABLE
44 using EngineManagerType = IntellVoiceEngineManager;
45 #elif defined(FIRST_STAGE_ONESHOT_ENABLE)
46 using EngineManagerType = OnlyFirstEngineManager;
47 #else
48 using EngineManagerType = DummyEngineManager;
49 #endif
50 using ServiceManagerType = IntellVoiceServiceManager<TriggerManagerType, EngineManagerType>;
51 }  // namespace IntellVoice
52 }  // namespace OHOS
53 #endif
54