Fix errors which are created by solving merge conflict
[platform/core/uifw/voice-control.git] / server / vcd_tidl.h
1 /*
2 * Copyright (c) 2022 Samsung Electronics Co., Ltd All Rights Reserved
3 *
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17
18 #ifndef __VCD_TIDL_h__
19 #define __VCD_TIDL_h__
20
21 #include "vcd_main.h"
22
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26
27 typedef enum {
28         VCD_CLIENT_TYPE_NORMAL,
29         VCD_CLIENT_TYPE_WIDGET,
30         VCD_CLIENT_TYPE_MANAGER
31 } vcd_client_type_e;
32
33 int vcd_tidl_open_connection();
34
35 int vcd_tidl_close_connection();
36
37 int vcdc_send_hello(int pid, vcd_client_type_e type);
38
39 int vcdc_send_set_volume(int manger_pid, float volume);
40
41 int vcdc_send_show_tooltip(int pid, bool show);
42
43 int vcdc_send_result(int pid, int manager_pid, int cmd_type);
44
45 int vcdc_send_pre_result_to_manager(int manager_pid, int event, const char* pre_result);
46
47 int vcdc_send_specific_engine_result_to_manager(int manager_pid, const char* engine_app_id, const char* event, const char* result);
48
49 int vcdc_send_result_to_manager(int manger_pid, int result_type);
50
51 int vcdc_send_speech_detected(int manger_pid);
52
53 // int vcdc_tidl_send_error(int reason, char *err_msg);
54
55 int vcdc_send_error_to_manager(int manager_pid, int reason, char *err_msg);
56
57 int vcdc_send_error_signal_to_app(int pid, int reason, char *err_msg);
58
59 int vcdc_send_manager_pid(int manager_pid);
60
61 int vcdc_send_service_state(vcd_state_e state);
62
63 int vcdc_send_dialog(int manger_pid, int pid, const char* disp_text, const char* utt_text, int continuous);
64
65 int vcdc_send_request_set_private_data(int pid, const char* key, const char* data);
66
67 int vcdc_send_request_get_private_data(int pid, const char* key, char** data);
68
69 int vcdc_send_asr_result(int pid, int event, const char* asr_result, int cmd_type, bool* is_consumed);
70
71 void vcdc_send_request_set_foreground(int pid, int value);
72
73 /* for auth */
74 int vcdc_send_request_auth_enable(int pid);
75
76 int vcdc_send_request_auth_disable(int pid);
77
78 int vcdc_send_request_auth_start(int pid);
79
80 int vcdc_send_request_auth_stop(int pid);
81
82 int vcdc_send_request_auth_cancel(int pid);
83
84 /* for TTS feedback */
85 int vcdc_send_feedback_audio_format_to_manager(int manager_pid, int rate, vc_audio_channel_e channel, vce_audio_type_e audio_type);
86
87 int vcdc_send_feedback_streaming(int pid, int utt_id, vc_feedback_event_e event, char* buffer, int len);
88
89 int vcdc_send_feedback_streaming_to_manager(int manager_pid, int pid, int utt_id, vc_feedback_event_e event, char* buffer, int len);
90
91
92 #ifdef __cplusplus
93 }
94 #endif
95
96 #endif  /* __VCD_TIDL_h__ */