Rename process_event to process_plugin_event 16/220116/1
authorJi-hoon Lee <dalton.lee@samsung.com>
Fri, 13 Dec 2019 04:14:57 +0000 (13:14 +0900)
committerJi-hoon Lee <dalton.lee@samsung.com>
Fri, 13 Dec 2019 04:14:57 +0000 (13:14 +0900)
Change-Id: I773bd187d329a005fdc9e6052c91b4b2d4bd4fde

inc/multi_assistant_service_plugin.h
plugins/wakeup-manager/inc/wakeup_manager.h
plugins/wakeup-manager/inc/wakeup_manager_wrapper.h
plugins/wakeup-manager/src/wakeup_manager.cpp
plugins/wakeup-manager/src/wakeup_manager_wrapper.cpp
src/multi_assistant_service_plugin.c

index cae0038..1f31ac0 100644 (file)
@@ -133,8 +133,8 @@ typedef int (*wakeup_manager_send_assistant_specific_command)(const char* appid,
 typedef int (*wakeup_manager_set_background_volume)(const char* appid, double ratio);
 #define MA_WAKEUP_MANAGER_FUNC_UPDATE_RECOGNITION_RESULT "wakeup_manager_update_recognition_result"
 typedef int (*wakeup_manager_update_recognition_result)(const char* appid, int result);
-#define MA_WAKEUP_MANAGER_FUNC_PROCESS_EVENT "wakeup_manager_process_event"
-typedef int (*wakeup_manager_process_event)(int event, void* data, int len);
+#define MA_WAKEUP_MANAGER_FUNC_PROCESS_PLUGIN_EVENT "wakeup_manager_process_plugin_event"
+typedef int (*wakeup_manager_process_plugin_event)(int event, void* data, int len);
 #define MA_WAKEUP_MANAGER_FUNC_START_STREAMING_UTTERANCE_DATA "wakeup_manager_start_streaming_utterance_data"
 typedef int (*wakeup_manager_start_streaming_utterance_data)(void);
 #define MA_WAKEUP_MANAGER_FUNC_STOP_STREAMING_UTTERANCE_DATA "wakeup_manager_stop_streaming_utterance_data"
@@ -192,7 +192,7 @@ typedef struct {
        wakeup_manager_send_assistant_specific_command                          send_assistant_specific_command;
        wakeup_manager_set_background_volume                                            set_background_volume;
        wakeup_manager_update_recognition_result                                        update_recognition_result;
-       wakeup_manager_process_event                                                            process_event;
+       wakeup_manager_process_plugin_event                                                     process_plugin_event;
        wakeup_manager_start_streaming_utterance_data                           start_streaming_utterance_data;
        wakeup_manager_stop_streaming_utterance_data                            stop_streaming_utterance_data;
        wakeup_manager_start_streaming_previous_utterance_data          start_streaming_previous_utterance_data;
index 85ce732..25c5498 100644 (file)
@@ -98,7 +98,7 @@ public:
        bool send_assistant_specific_command(string appid, string command);
        bool set_background_volume(string appid, double ratio);
        bool update_recognition_result(string appid, int result);
-       bool process_event(mas_plugin_event_e event, void* data, int len);
+       bool process_plugin_event(mas_plugin_event_e event, void* data, int len);
        bool get_audio_format(int* rate, int* channel, int* audio_type);
        bool get_audio_source_type(char** type);
        bool set_language(string language);
index 54fd533..1477360 100644 (file)
@@ -93,7 +93,7 @@ EXPORT_API int wakeup_manager_set_background_volume(const char *appid, double ra
 
 EXPORT_API int wakeup_manager_update_recognition_result(const char *appid, int result);
 
-EXPORT_API int wakeup_manager_process_event(mas_plugin_event_e event, void* data, int len);
+EXPORT_API int wakeup_manager_process_plugin_event(mas_plugin_event_e event, void* data, int len);
 
 EXPORT_API int wakeup_manager_start_streaming_utterance_data(void);
 
index 7119251..7372efb 100644 (file)
@@ -114,7 +114,7 @@ bool CWakeupManager::initialize()
        mWakeupEngineManager.initialize();
 
        mas_dependency_plugin_proxy_interface interface;
-       interface.process_event = wakeup_manager_process_event;
+       interface.process_event = wakeup_manager_process_plugin_event;
        interface.feed_audio_data = wakeup_manager_feed_audio_data;
        //interface.send_dependency_module_command = wakeup_manager_send_dependency_module_command;
        interface.wakeup_assistant = wakeup_manager_wakeup_assistant;
@@ -467,7 +467,7 @@ static long get_current_milliseconds_after_epoch()
        return value.count();
 }
 
-bool CWakeupManager::process_event(mas_plugin_event_e event, void* data, int len)
+bool CWakeupManager::process_plugin_event(mas_plugin_event_e event, void* data, int len)
 {
        MWR_LOGD("[ENTER] : %d", event);
        if (WAKEUP_MANAGER_STATE_INACTIVE == mWakeupManagerState)
index 5fe6469..5dc12dc 100644 (file)
@@ -367,12 +367,12 @@ int wakeup_manager_update_recognition_result(const char* appid, int result)
        return 0;
 }
 
-int wakeup_manager_process_event(mas_plugin_event_e event, void* data, int len)
+int wakeup_manager_process_plugin_event(mas_plugin_event_e event, void* data, int len)
 {
        MWR_LOGD("[ENTER]");
 
        if (nullptr == g_wakeup_manager) return -1;
-       g_wakeup_manager->process_event(event, data, len);
+       g_wakeup_manager->process_plugin_event(event, data, len);
 
        MWR_LOGD("[END]");
        return 0;
index a486a84..d9a1e6e 100644 (file)
@@ -435,9 +435,9 @@ int multi_assistant_service_plugin_initialize(void)
        _wakeup_manager_interface.update_recognition_result =
                (wakeup_manager_update_recognition_result)dlsym(g_handle,
                MA_WAKEUP_MANAGER_FUNC_UPDATE_RECOGNITION_RESULT);
-       _wakeup_manager_interface.process_event =
-               (wakeup_manager_process_event)dlsym(g_handle,
-               MA_WAKEUP_MANAGER_FUNC_PROCESS_EVENT);
+       _wakeup_manager_interface.process_plugin_event =
+               (wakeup_manager_process_plugin_event)dlsym(g_handle,
+               MA_WAKEUP_MANAGER_FUNC_PROCESS_PLUGIN_EVENT);
        _wakeup_manager_interface.start_streaming_utterance_data =
                (wakeup_manager_start_streaming_utterance_data)dlsym(g_handle,
                MA_WAKEUP_MANAGER_FUNC_START_STREAMING_UTTERANCE_DATA);
@@ -817,9 +817,9 @@ int multi_assistant_service_plugin_process_event(int event, void *data, int len)
 {
        int ret = -1;
        if (NULL != g_handle) {
-               wakeup_manager_process_event func = _wakeup_manager_interface.process_event;
+               wakeup_manager_process_plugin_event func = _wakeup_manager_interface.process_plugin_event;
                if (NULL == func) {
-                       MAS_LOGE("[ERROR] symbol lookup failed : %s", MA_WAKEUP_MANAGER_FUNC_PROCESS_EVENT);
+                       MAS_LOGE("[ERROR] symbol lookup failed : %s", MA_WAKEUP_MANAGER_FUNC_PROCESS_PLUGIN_EVENT);
                } else {
                        ret = func((mas_plugin_event_e)event, data, len);
                        if (0 != ret) {