1f5853417a87ace0012941634ae66d60c756b6c0
[platform/core/uifw/stt.git] / server / sttd_config.h
1 /*
2 *  Copyright (c) 2011-2014 Samsung Electronics Co., Ltd All Rights Reserved 
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 *  http://www.apache.org/licenses/LICENSE-2.0
7 *  Unless required by applicable law or agreed to in writing, software
8 *  distributed under the License is distributed on an "AS IS" BASIS,
9 *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
10 *  See the License for the specific language governing permissions and
11 *  limitations under the License.
12 */
13
14
15 #ifndef __STTD_CONFIG_H_
16 #define __STTD_CONFIG_H_
17
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
21
22 typedef void (*sttd_config_engine_changed_cb)(const char* engine_id, const char* language, bool support_silence, bool need_credential, void* user_data);
23
24 typedef void (*sttd_config_language_changed_cb)(const char* language, void* user_data);
25
26 typedef void (*sttd_config_silence_changed_cb)(bool value, void* user_data);
27
28
29 int sttd_config_initialize(sttd_config_engine_changed_cb engine_cb, 
30                         sttd_config_language_changed_cb lang_cb, 
31                         sttd_config_silence_changed_cb silence_cb, 
32                         void* user_data);
33
34 int sttd_config_finalize();
35
36 int sttd_config_set_default_engine(const char* engine_id);
37
38 int sttd_config_get_default_engine(char** engine_id);
39
40 int sttd_config_get_default_language(char** language);
41
42 int sttd_config_get_default_silence_detection(int* silence);
43
44
45 int sttd_config_time_add(int index, int event, const char* text, long start_time, long end_time);
46
47 int sttd_config_time_save();
48
49 int sttd_config_time_reset();
50
51 #ifdef __cplusplus
52 }
53 #endif
54
55 #endif /* __STTD_CONFIG_H_ */