Rename function name and Rearrange codes 72/278972/1
authorsooyeon <sooyeon.kim@samsung.com>
Thu, 30 Jun 2022 08:44:12 +0000 (17:44 +0900)
committersooyeon <sooyeon.kim@samsung.com>
Fri, 29 Jul 2022 01:25:59 +0000 (10:25 +0900)
Change-Id: Iaa053e9004dd3aaf3e6caa99bfcab5288d73211b
Signed-off-by: sooyeon <sooyeon.kim@samsung.com>
server/vcd_engine_agent.c
server/vcd_server.c
server/vcd_tidl.c
server/vcd_tidl.h

index 9c3c9c1..c000e7b 100644 (file)
@@ -922,7 +922,7 @@ int vcd_engine_agent_start_recording()
                SLOG(LOG_ERROR, TAG_VCD, "[Server ERROR] Fail to start recorder : result(%d)", ret);
                vcd_engine_recognize_cancel();
                /* Send error cb to manager */
-               vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.send_rc_fail");
+               vcdc_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.send_rc_fail");
                return ret;
        }
 
index 16717a5..f22895f 100644 (file)
@@ -145,9 +145,9 @@ static int __server_recorder_callback(const void* data, const unsigned int lengt
                ecore_timer_add(0, __cancel_by_interrupt, NULL);
                /* Send error cb to manager */
                if (VCE_ERROR_OUT_OF_NETWORK == ret) {
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_TIMED_OUT, "voice_framework.error.engine.set_recording_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_TIMED_OUT, "voice_framework.error.engine.set_recording_fail");
                } else {
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), ret, "voice_framework.error.engine.set_recording_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), ret, "voice_framework.error.engine.set_recording_fail");
                }
                return VCD_ERROR_NONE;
        }
@@ -1123,7 +1123,7 @@ int vcd_send_error(vce_error_e error, const char* msg, void *user_data)
                int pid = __get_tts_played_pid();
                ret = vcdc_send_error_signal_to_app(pid, error, error_msg);
        } else {
-               ret = vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), error, error_msg);
+               ret = vcdc_send_error_to_manager(vcd_client_manager_get_pid(), error, error_msg);
                ecore_main_loop_thread_safe_call_async(__cancel_by_error, NULL);
        }
 
@@ -1898,7 +1898,7 @@ static int __start_internal_recognition()
                /* Send error cb to manager */
                int pid = vcd_client_widget_get_foreground_pid();
                if (-1 != pid)
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.collect_command_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.collect_command_fail");
                return VCD_ERROR_OPERATION_FAILED;
        }
 
@@ -1909,7 +1909,7 @@ static int __start_internal_recognition()
                /* Send error cb to manager */
                int pid = vcd_client_widget_get_foreground_pid();
                if (-1 != pid)
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.engine.set_commands_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.engine.set_commands_fail");
                return VCD_ERROR_OPERATION_FAILED;
        }
 
@@ -1929,7 +1929,7 @@ static int __start_internal_recognition()
                /* Send error cb to manager */
                int pid = vcd_client_widget_get_foreground_pid();
                if (-1 != pid)
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), ret, "voice_framework.error.engine.start_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), ret, "voice_framework.error.engine.start_fail");
                return ret;
        }
 
@@ -1944,7 +1944,7 @@ static int __start_internal_recognition()
                /* Send error cb to manager */
                int pid = vcd_client_widget_get_foreground_pid();
                if (-1 != pid)
-                       vcdc_tidl_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.send_rc_fail");
+                       vcdc_send_error_to_manager(vcd_client_manager_get_pid(), VCD_ERROR_OPERATION_FAILED, "voice_framework.error.vcfw.send_rc_fail");
                return ret;
        }
 #endif
index 237488f..631643b 100644 (file)
@@ -57,7 +57,9 @@ extern int __setting_tidl_open_connection();
 extern int __setting_tidl_close_connection();
 
 
-/* For common request */
+/**
+ * For common request
+ */
 static void __request_tidl_connect(vcd_client_type_e type, int pid)
 {
        char* type_str = NULL;
@@ -1916,7 +1918,9 @@ int __setting_tidl_close_connection()
 }
 
 
-
+/**
+ * Functions for sending the information to client sides
+ */
 int vcdc_send_error_signal_to_app(int pid, int reason, char *err_msg)
 {
        if (NULL == err_msg) {
@@ -2376,7 +2380,7 @@ int vcdc_send_dialog(int manager_pid, int pid, const char* disp_text, const char
        return VCD_ERROR_NONE;
 }
 
-int vcdc_tidl_send_error_to_manager(int manager_pid, int reason, char *err_msg)
+int vcdc_send_error_to_manager(int manager_pid, int reason, char *err_msg)
 {
        SLOG(LOG_ERROR, TAG_VCD, "[TIDL] Send error signal to manager");
 
index 839258b..4b555f3 100644 (file)
@@ -52,7 +52,7 @@ int vcdc_send_speech_detected(int manger_pid);
 
 // int vcdc_tidl_send_error(int reason, char *err_msg);
 
-int vcdc_tidl_send_error_to_manager(int manager_pid, int reason, char *err_msg);
+int vcdc_send_error_to_manager(int manager_pid, int reason, char *err_msg);
 
 int vcdc_send_error_signal_to_app(int pid, int reason, char *err_msg);