2fd8fd6a43de1075c8cb065764d9c9840c2bb316
[platform/core/uifw/stt.git] / common / stt_defs.h
1 /*
2 *  Copyright (c) 2011-2016 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 __STT_DEFS_H__
16 #define __STT_DEFS_H__
17
18 #include <tzplatform_config.h>
19
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23
24 /******************************************************************************************
25 * Definition for Dbus
26 *******************************************************************************************/
27
28 #define STT_CLIENT_SERVICE_NAME         "org.tizen.voice.sttclient"
29 #define STT_CLIENT_SERVICE_OBJECT_PATH  "/org/tizen/voice/sttclient"
30 #define STT_CLIENT_SERVICE_INTERFACE    "org.tizen.voice.sttclient"
31
32 #define STT_SERVER_SERVICE_NAME         "org.tizen.voice.sttserver"
33 #define STT_SERVER_SERVICE_OBJECT_PATH  "/org/tizen/voice/sttserver"
34 #define STT_SERVER_SERVICE_INTERFACE    "org.tizen.voice.sttserver"
35
36 #define STT_SERVER_CUSTOM_SERVICE_NAME         "org.tizen.voice.sttservercustom"
37 #define STT_SERVER_CUSTOM_SERVICE_OBJECT_PATH  "/org/tizen/voice/sttservercustom"
38 #define STT_SERVER_CUSTOM_SERVICE_INTERFACE    "org.tizen.voice.sttservercustom"
39
40 /******************************************************************************************
41 * Definitions for Vconf Keys
42 *******************************************************************************************/
43
44 #define STT_ENGINE_DB_DEFAULT           "db/voice/stt/engine/default"
45 #define STT_ENGINE_DB_CUSTOM            "db/voice/stt/engine/custom"
46
47 /******************************************************************************************
48 * Message Definition for Client
49 *******************************************************************************************/
50
51 #define STT_METHOD_HELLO                "stt_method_hello"
52 #define STT_METHOD_INITIALIZE           "stt_method_initialize"
53 #define STT_METHOD_FINALIZE             "stt_method_finalilze"
54 #define STT_METHOD_SET_CURRENT_ENGINE   "stt_method_set_current_engine"
55 #define STT_METHOD_GET_SUPPORT_LANGS    "stt_method_get_support_langs"
56 #define STT_METHOD_GET_CURRENT_LANG     "stt_method_get_current_lang"
57 #define STT_METHOD_IS_TYPE_SUPPORTED    "stt_method_is_recognition_type_supported"
58 #define STT_METHOD_CHECK_APP_AGREED     "stt_method_check_app_agreed"
59 #define STT_METHOD_SET_PRIVATE_DATA     "stt_method_set_private_data"
60 #define STT_METHOD_GET_PRIVATE_DATA     "stt_method_get_private_data"
61
62 #define STT_METHOD_SET_START_SOUND      "stt_method_set_start_sound"
63 #define STT_METHOD_UNSET_START_SOUND    "stt_method_unset_start_sound"
64 #define STT_METHOD_SET_STOP_SOUND       "stt_method_set_stop_sound"
65 #define STT_METHOD_UNSET_STOP_SOUND     "stt_method_unset_stop_sound"
66
67 #define STT_METHOD_START                "stt_method_start"
68 #define STT_METHOD_STOP                 "stt_method_stop"
69 #define STT_METHOD_CANCEL               "stt_method_cancel"
70 #define STT_METHOD_START_FILE_RECONITION "stt_method_start_recognition"
71
72 #define STTD_METHOD_RESULT              "sttd_method_result"
73 #define STTD_METHOD_ERROR               "sttd_method_error"
74 #define STTD_METHOD_HELLO               "sttd_method_hello"
75 #define STTD_METHOD_SET_STATE           "sttd_method_set_state"
76 #define STTD_METHOD_SET_VOLUME          "sttd_method_set_volume"
77 #define STTD_METHOD_SPEECH_STATUS       "sttd_method_speech_status"
78
79 #define STT_METHOD_START_FILE           "stt_method_start_file"
80 #define STT_METHOD_CANCEL_FILE          "stt_method_cancel_file"
81
82
83 /******************************************************************************************
84 * Defines for configuration
85 *******************************************************************************************/
86
87 #define STT_CONFIG_BASE         tzplatform_mkpath(TZ_USER_HOME, "share/.voice")
88 #define STT_CONFIG                      tzplatform_mkpath(TZ_USER_HOME, "share/.voice/stt-config.xml")
89 #define STT_DEFAULT_CONFIG              tzplatform_mkpath(TZ_SYS_RO_SHARE, "/voice/stt/1.0/stt-config.xml")
90
91 #define STT_TIME_INFO_PATH              tzplatform_mkpath(TZ_USER_HOME, "share/.voice/stt-time.xml")
92
93 #define STT_DEFAULT_ENGINE              tzplatform_mkpath(TZ_SYS_RO_SHARE, "/voice/stt/1.0/engine")
94 #define STT_DEFAULT_ENGINE_INFO         tzplatform_mkpath(TZ_SYS_RO_SHARE, "/voice/stt/1.0/engine-info")
95 #define STT_DEFAULT_ENGINE_SETTING      tzplatform_mkpath(TZ_SYS_RO_SHARE, "/voice/stt/1.0/engine-setting")
96
97 #define STT_HOME                        tzplatform_mkpath(TZ_USER_HOME, "share/.voice/stt")
98 #define STT_DOWNLOAD_BASE               tzplatform_mkpath(TZ_USER_HOME, "share/.voice/stt/1.0")
99 #define STT_DOWNLOAD_ENGINE_INFO        tzplatform_mkpath(TZ_USER_HOME, "share/.voice/stt/1.0/engine-info")
100
101 #define STT_BASE_LANGUAGE               "en_US"
102
103 #define STT_RETRY_COUNT                 5
104
105 #define STT_FEATURE_PATH                "tizen.org/feature/speech.recognition"
106 #define STT_MIC_FEATURE_PATH            "tizen.org/feature/microphone"
107
108 #define STT_PRIVILEGE_RECORDER                  "http://tizen.org/privilege/recorder"
109 #define STT_PRIVILEGE_APPLAUNCH                 "http://tizen.org/privilege/appmanager.launch"
110
111 #ifdef __cplusplus
112 }
113 #endif
114
115 #endif /* __STT_DEFS_H__ */