Revert "Add ttse_send_personal_voice API for saving personal voice information" 55/316955/1 accepted/tizen_unified_dev accepted/tizen/unified/20240905.164030 accepted/tizen/unified/dev/20240910.111606 accepted/tizen/unified/x/20240906.021658
authordyamy-lee <dyamy.lee@samsung.com>
Mon, 2 Sep 2024 01:53:41 +0000 (10:53 +0900)
committerdyamy-lee <dyamy.lee@samsung.com>
Mon, 2 Sep 2024 01:55:49 +0000 (10:55 +0900)
This reverts commit 9d26075cda1ba702f89fbf6a072c1118f6f88f4d.

Change-Id: If1e9031e4050d02756873c7bed098b0864ba1386

12 files changed:
common/tts_config_mgr.c
common/tts_config_mgr.h
common/tts_config_parser.c
common/tts_config_parser.h
common/tts_defs.h
include/ttse.h
packaging/tts.spec
server/ttsd_config.c
server/ttsd_config.h
server/ttsd_server.c
server/ttsd_server.h
server/ttse.c

index 1b2b99b..a16ee6f 100644 (file)
@@ -1329,16 +1329,6 @@ int tts_config_mgr_initialize(unsigned int uid, tts_config_client_type_e client_
                }
        }
 
-       if (0 != access(TTS_DOWNLOAD_PERSONAL_INFO, F_OK)) {
-               if (0 != mkdir(TTS_DOWNLOAD_PERSONAL_INFO, S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH)) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to make directory : %s", TTS_DOWNLOAD_PERSONAL_INFO);
-                       release_config_client(uid);
-                       return TTS_CONFIG_ERROR_OPERATION_FAILED;
-               } else {
-                       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "Success to make directory : %s", TTS_DOWNLOAD_PERSONAL_INFO);
-               }
-       }
-
        SLOG(LOG_INFO, TAG_TTSCONFIG, "Client type : %d", client_type);
        g_client_type |= client_type;
 
@@ -2381,45 +2371,3 @@ int tts_config_mgr_set_instant_reprepare_client(const unsigned int uid)
 
        return ret;
 }
-
-int tts_config_mgr_update_personal_voice(const char* engine_id, const char* language, const char* unique_id, const char* display_name, const char* device_name)
-{
-       char* default_engine = get_default_engine_app_id();
-       // tts_engine_info_s *engine_info = __get_engine_info(default_engine);
-       // free(default_engine);
-       // if (NULL == engine_info) {
-       //      SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] engine info is NULL");
-       //      return TTS_CONFIG_ERROR_ENGINE_NOT_FOUND;
-       // }
-
-       engine_id = strdup(default_engine);
-
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] engine id = %s", engine_id);
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] language(%s), unique_id(%s), display_name(%s), device_name(%s)", language, unique_id, display_name, device_name);
-       if (NULL == engine_id || NULL == language || NULL == unique_id || NULL == display_name || NULL == device_name) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Input Parameter is null");
-               return TTS_CONFIG_ERROR_INVALID_PARAMETER;
-       }
-
-       char filepath[512] = {'\0',};
-
-       memset(filepath, '\0', 512);
-       snprintf(filepath, 512, "%s/%s-%s", TTS_DOWNLOAD_PERSONAL_INFO, engine_id, "personal.xml");
-
-       SECURE_SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[CONFIG] Filepath(%s)", filepath);
-
-       if (0 != tts_parser_update_personal_info(filepath, engine_id, language, unique_id, display_name, device_name)) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to update personal info xml");
-               return -1;
-       }
-
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] Finish update personal info");
-       tts_personal_info_s* info = NULL;
-       int ret = tts_parser_get_personal_info(filepath, &info);
-       if (0 != ret) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to get personal info");
-               return -1;
-       }
-
-       return 0;
-}
index 3f6f694..a387d48 100644 (file)
@@ -129,8 +129,6 @@ int tts_config_mgr_get_instant_reprepare_client(unsigned int *uid);
 
 int tts_config_mgr_set_instant_reprepare_client(const unsigned int uid);
 
-int tts_config_mgr_update_personal_voice(const char* engine_id, const char* language, const char* unique_id, const char* display_name, const char* device_name);
-
 
 #ifdef __cplusplus
 }
index 374db73..e9cf157 100644 (file)
@@ -16,7 +16,6 @@
 #include <sys/stat.h>
 #include <unistd.h>
 #include <vconf.h>
-#include <errno.h>
 
 #include "tts_config_parser.h"
 #include "tts_defs.h"
 #define TTS_TAG_VOICE_TYPE_MALE                "male"
 #define TTS_TAG_VOICE_TYPE_CHILD       "child"
 
-#define TTS_TAG_PERSONAL_BASE_TAG      "tts-personal-voice"
-#define TTS_TAG_PERSONAL_VOICE_SET             "personal-voices"
-#define TTS_TAG_PERSONAL_VOICE         "personal-voice"
-#define TTS_TAG_PERSONAL_VOICE_LANGUAGE        "language"
-#define TTS_TAG_PERSONAL_VOICE_UNIQUE_ID       "unique-id"
-#define TTS_TAG_PERSONAL_VOICE_DISPLAY_NAME    "display-name"
-#define TTS_TAG_PERSONAL_VOICE_DEVICE_NAME     "device-name"
-#define TTS_TAG_PERSONAL_VOICE_ENGINE_ID       "id"
-
 #define TTS_MAX_TEXT_SIZE      2000
 #define VOLUME_BASE_VALUE      100.0
 
@@ -62,356 +52,10 @@ char g_engine_id[128] = {0,};
 char g_setting[128] = {0,};
 char g_language[128] = {0,};
 
-static xmlDocPtr g_personal_info_doc = NULL;
-
 static tts_config_s* g_config_info = NULL;
 
 static pthread_mutex_t g_config_info_mutex = PTHREAD_MUTEX_INITIALIZER;
 
-int __create_personal_info_xml(const char* engine_id, const char* language, const char* unique_id, const char* display_name, const char* device_name)
-{
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "@@@ Create personal info doc");
-       g_personal_info_doc = xmlNewDoc((xmlChar*)"1.0");
-       if (NULL == g_personal_info_doc) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to new doc");
-               return -1;
-       }
-       xmlNodePtr root = NULL;
-       xmlNodePtr cur = NULL;
-
-       root = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_BASE_TAG);
-       if (NULL == root) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to get new node");
-               return -1;
-       }
-
-       xmlDocSetRootElement(g_personal_info_doc, root);
-
-       xmlNodePtr node = NULL;
-       xmlNodePtr personal_voice_node = NULL;
-
-       node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_SET);
-
-       personal_voice_node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE);
-
-       cur = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_LANGUAGE);
-       xmlNodeSetContent(cur, (const xmlChar*)language);
-       xmlAddChild(personal_voice_node, cur);
-
-       cur = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_UNIQUE_ID);
-       xmlNodeSetContent(cur, (const xmlChar*)unique_id);
-       xmlAddChild(personal_voice_node, cur);
-
-       cur = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_DISPLAY_NAME);
-       xmlNodeSetContent(cur, (const xmlChar*)display_name);
-       xmlAddChild(personal_voice_node, cur);
-
-       cur = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_DEVICE_NAME);
-       xmlNodeSetContent(cur, (const xmlChar*)device_name);
-       xmlAddChild(personal_voice_node, cur);
-
-       xmlAddChild(node, personal_voice_node);
-       xmlAddChild(root, node);
-
-       node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_ENGINE_ID);
-       xmlNodeSetContent(node, (const xmlChar*)engine_id);
-       xmlAddChild(root, node);
-
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] Finish to create personal voice info");
-
-       SLOG(LOG_DEBUG, TAG_TTSCONFIG, "@@@");
-       return 0;
-}
-
-int tts_parser_update_personal_info(const char* path, const char* engine_id, const char* language, const char* unique_id, const char* display_name, const char* device_name)
-{
-       if (NULL == path) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Input parameter is NULL");
-               return -1;
-       }
-
-       if (0 == access(path, F_OK)) {
-               SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] Success to access to %s", path);
-
-               xmlNodePtr cur = NULL;
-
-               g_personal_info_doc = xmlParseFile(path);
-               if (g_personal_info_doc == NULL) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to parse xml file");
-                       return -1;
-               }
-               cur = xmlDocGetRootElement(g_personal_info_doc);
-               if (cur == NULL) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Empty document. doc path(%s, %p)", path, g_personal_info_doc);
-                       xmlFreeDoc(g_personal_info_doc);
-                       g_personal_info_doc = NULL;
-                       return -1;
-               }
-
-               if (xmlStrcmp(cur->name, (const xmlChar *)TTS_TAG_PERSONAL_BASE_TAG)) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] The wrong type, root node is NOT 'tts-personal-info'. doc path(%s, %p)", path, g_personal_info_doc);
-                       xmlFreeDoc(g_personal_info_doc);
-                       g_personal_info_doc = NULL;
-                       return -1;
-               }
-
-               cur = cur->xmlChildrenNode; // TTS_TAG_PERSONAL_VOICE_SET
-               if (cur == NULL) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Empty document. doc path(%s, %p)", path, g_personal_info_doc);
-                       xmlFreeDoc(g_personal_info_doc);
-                       g_personal_info_doc = NULL;
-                       return -1;
-               }
-
-               while (cur != NULL) {
-                       if (0 == xmlStrcmp(cur->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_SET)) {
-                               xmlNodePtr personal_voice_node = NULL;
-                               personal_voice_node = xmlNewNode(NULL, (const xmlChar *)TTS_TAG_PERSONAL_VOICE);
-
-                               xmlNodePtr info_node = NULL;
-                               info_node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_LANGUAGE);
-                               xmlNodeSetContent(info_node, (const xmlChar*)language);
-                               xmlAddChild(personal_voice_node, info_node);
-
-                               info_node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_UNIQUE_ID);
-                               xmlNodeSetContent(info_node, (const xmlChar*)unique_id);
-                               xmlAddChild(personal_voice_node, info_node);
-
-                               info_node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_DISPLAY_NAME);
-                               xmlNodeSetContent(info_node, (const xmlChar*)display_name);
-                               xmlAddChild(personal_voice_node, info_node);
-
-                               info_node = xmlNewNode(NULL, (const xmlChar*)TTS_TAG_PERSONAL_VOICE_DEVICE_NAME);
-                               xmlNodeSetContent(info_node, (const xmlChar*)device_name);
-                               xmlAddChild(personal_voice_node, info_node);
-
-                               xmlAddChild(cur, personal_voice_node);
-                               SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] Finish to add personal voice info");
-                               // break;
-                       }
-                       cur = cur->next;
-               }
-       } else {
-               switch (errno) {
-                       case ENOENT:
-                               SLOG(LOG_INFO, TAG_TTSCONFIG, "[INFO] No such file or directory. Create new personal info.");
-                               int ret = __create_personal_info_xml(engine_id, language, unique_id, display_name, device_name);
-                               if (0 != ret) {
-                                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to create new personal info");
-                                       return -1;
-                               }
-                               SLOG(LOG_INFO, TAG_TTSCONFIG, "[INFO] Success to create new personal info");
-                               break;
-                       default:
-                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to access to %s (%d)", path, errno);
-                               return -1;
-               }
-       }
-
-       int ret = xmlSaveFormatFile(path, g_personal_info_doc, 1);
-       SLOG(LOG_ERROR, TAG_TTSCONFIG, "xmlSaveFile to path(%s) (%d)", path, ret);
-       if (0>ret) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Save result : %d", ret);
-       } else {
-               static FILE* pFile;
-               pFile = fopen(path, "r");
-               int fd = -1;
-               if (NULL == pFile) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to open file %s", path);
-               } else {
-                       fd = fileno(pFile);
-                       fsync(fd);
-                       fclose(pFile);
-                       SLOG(LOG_INFO, TAG_TTSCONFIG, "[DEBUG] Success to fsync %s", path);
-               }
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[DEBUG] Success to save %s", path);
-       }
-
-       /* Set mode */
-       if (0 > chmod(path, 0664)) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to change file mode : %d", ret);
-       }
-
-       if (NULL != g_personal_info_doc) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] doc path(%p)", g_personal_info_doc);
-               xmlFreeDoc(g_personal_info_doc);
-               g_personal_info_doc = NULL;
-       }
-
-       return 0;
-}
-
-int tts_parser_get_personal_info(const char* path, tts_personal_info_s** personal_info)
-{
-       if (NULL == path || NULL == personal_info) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Input parameter is NULL");
-               return -1;
-       }
-
-       xmlDocPtr doc = NULL;
-       xmlNodePtr cur = NULL;
-
-       if (0 == access(path, F_OK)) {
-               SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] Success to access to %s", path);
-               doc = xmlParseFile(path);
-               if (doc == NULL) {
-                       SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to parse xml file. errno(%d)", errno);
-                       return -1;
-               }
-       } else {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Fail to access to %s (%d)", path, errno);
-               return -1;
-       }
-
-       cur = xmlDocGetRootElement(doc);
-       if (cur == NULL) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Empty document. doc path(%s, %p)", path, doc);
-               xmlFreeDoc(doc);
-               doc = NULL;
-               return -1;
-       }
-
-       if (xmlStrcmp(cur->name, (const xmlChar *)TTS_TAG_PERSONAL_BASE_TAG)) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] The wrong type, root node is NOT 'tts-personal-voice'. doc path(%s, %p)", path, doc);
-               xmlFreeDoc(doc);
-               doc = NULL;
-               return -1;
-       }
-
-       cur = cur->xmlChildrenNode; // tts_tag_personal_voice_set
-       if (cur == NULL) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Empty document. doc path(%s, %p)", path, doc);
-               xmlFreeDoc(doc);
-               doc = NULL;
-               return -1;
-       }
-
-       /* alloc personal info */
-       tts_personal_info_s* temp;
-       temp = (tts_personal_info_s*)calloc(1, sizeof(tts_personal_info_s));
-       if (NULL == temp) {
-               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Out of memory. doc path(%s, %p)", path, doc);
-               xmlFreeDoc(doc);
-               doc = NULL;
-               return -1;
-       }
-
-       temp->engine_id = NULL;
-       temp->personal_voices = NULL;
-
-       while (cur != NULL) {
-               if (0 == xmlStrcmp(cur->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_SET)) {
-                       xmlNodePtr personal_voice_node = NULL;
-                       personal_voice_node = cur->xmlChildrenNode;
-
-                       while (NULL != personal_voice_node) {
-                               if (0 == xmlStrcmp(personal_voice_node->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE)) {
-                                       xmlNodePtr info_node = NULL;
-                                       info_node = personal_voice_node->xmlChildrenNode;
-
-                                       tts_config_personal_s* temp_personal_voice = (tts_config_personal_s*)calloc(1, sizeof(tts_config_personal_s));
-                                       if (NULL == temp_personal_voice) {
-                                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Out of memory");
-                                               break;
-                                       }
-
-                                       while (NULL != info_node) {
-                                               if (0 == xmlStrcmp(info_node->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_LANGUAGE)) {
-                                                       xmlChar *key = xmlNodeGetContent(info_node);
-                                                       if (NULL != key) {
-                                                               if (NULL != temp_personal_voice->language) {
-                                                                       free(temp_personal_voice->language);
-                                                                       temp_personal_voice->language = NULL;
-                                                               }
-                                                               temp_personal_voice->language = strdup((char*)key);
-                                                               xmlFree(key);
-                                                               key = NULL;
-                                                       } else {
-                                                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] <%s> has no content", TTS_TAG_PERSONAL_VOICE_LANGUAGE);
-                                                       }
-                                               } else if (0 == xmlStrcmp(info_node->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_UNIQUE_ID)) {
-                                                       xmlChar *key = xmlNodeGetContent(info_node);
-                                                       if (NULL != key) {
-                                                               if (NULL != temp_personal_voice->unique_id) {
-                                                                       free(temp_personal_voice->unique_id);
-                                                                       temp_personal_voice->unique_id = NULL;
-                                                               }
-                                                               temp_personal_voice->unique_id = strdup((char*)key);
-                                                               xmlFree(key);
-                                                               key = NULL;
-                                                       } else {
-                                                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] <%s> has no content", TTS_TAG_PERSONAL_VOICE_UNIQUE_ID);
-                                                       }
-                                               } else if (0 == xmlStrcmp(info_node->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_DISPLAY_NAME)) {
-                                                       xmlChar *key = xmlNodeGetContent(info_node);
-                                                       if (NULL != key) {
-                                                               if (NULL != temp_personal_voice->display_name) {
-                                                                       free(temp_personal_voice->display_name);
-                                                                       temp_personal_voice->display_name = NULL;
-                                                               }
-                                                               temp_personal_voice->display_name = strdup((char*)key);
-                                                               xmlFree(key);
-                                                               key = NULL;
-                                                       } else {
-                                                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] <%s> has no content", TTS_TAG_PERSONAL_VOICE_DISPLAY_NAME);
-                                                       }
-                                               } else if (0 == xmlStrcmp(info_node->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_DEVICE_NAME)) {
-                                                       xmlChar *key = xmlNodeGetContent(info_node);
-                                                       if (NULL != key) {
-                                                               if (NULL != temp_personal_voice->device_name) {
-                                                                       free(temp_personal_voice->device_name);
-                                                                       temp_personal_voice->device_name = NULL;
-                                                               }
-                                                               temp_personal_voice->device_name = strdup((char*)key);
-                                                               xmlFree(key);
-                                                               key = NULL;
-                                                       } else {
-                                                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] <%s> has no content", TTS_TAG_PERSONAL_VOICE_DEVICE_NAME);
-                                                       }
-                                               }
-                                               info_node = info_node->next;
-                                       }
-
-                                       temp->personal_voices = g_slist_append(temp->personal_voices, temp_personal_voice);
-                               }
-                               personal_voice_node = personal_voice_node->next;
-                       }
-               } else if (0 == xmlStrcmp(cur->name, (const xmlChar *)TTS_TAG_PERSONAL_VOICE_ENGINE_ID)) {
-                       xmlChar *key = xmlNodeGetContent(cur);
-                       if (NULL != key) {
-                               if (NULL != temp->engine_id) {
-                                       free(temp->engine_id);
-                                       temp->engine_id = NULL;
-                               }
-                               temp->engine_id = strdup((char*)key);
-                               xmlFree(key);
-                               key = NULL;
-                       } else {
-                               SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] <%s> has no content", TTS_TAG_PERSONAL_VOICE_ENGINE_ID);
-                       }
-               }
-               cur = cur->next;
-       }
-
-       if (NULL != doc) {
-               SLOG(LOG_DEBUG, TAG_TTSCONFIG, "[DEBUG] doc path(%s, %p)", path, doc);
-               xmlFreeDoc(doc);
-               doc = NULL;
-       }
-
-       if (NULL == temp->engine_id) {
-               /* Invalid engine */
-               SECURE_SLOG(LOG_ERROR, TAG_TTSCONFIG, "[ERROR] Invalid engine : %s", path);
-               // free personal info
-               return -1;
-       }
-
-       *personal_info = temp;
-
-       return 0;
-
-}
-
 int tts_parser_get_engine_info(const char* path, tts_engine_info_s** engine_info)
 {
        if (NULL == path || NULL == engine_info) {
index db59b2a..a39d935 100644 (file)
@@ -57,18 +57,6 @@ typedef struct {
        double bg_volume_ratio;
 } tts_config_s;
 
-typedef struct {
-       char*   language;
-       char*   unique_id;
-       char*   display_name;
-       char*   device_name;
-} tts_config_personal_s;
-
-typedef struct {
-       char*   engine_id;
-       GSList* personal_voices;
-} tts_personal_info_s;
-
 
 /* Get engine information */
 int tts_parser_get_engine_info(const char* path, tts_engine_info_s** engine_info);
@@ -103,10 +91,6 @@ int tts_parser_copy_xml(const char* original, const char* destination);
 
 int tts_parser_reset();
 
-int tts_parser_update_personal_info(const char* path, const char* engine_id, const char* language, const char* unique_id, const char* display_name, const char* device_name);
-
-int tts_parser_get_personal_info(const char* path, tts_personal_info_s** personal_info);
-
 #ifdef __cplusplus
 }
 #endif
index 0f6953e..18a300d 100644 (file)
@@ -111,7 +111,6 @@ extern "C" {
 
 #define TTS_HOME               tzplatform_mkpath(tzplatform_getid("TZ_SYS_GLOBALUSER_DATA"), ".voice/tts")
 #define TTS_DOWNLOAD_ENGINE_INFO               tzplatform_mkpath(tzplatform_getid("TZ_SYS_GLOBALUSER_DATA"), ".voice/tts/engine-info")
-#define TTS_DOWNLOAD_PERSONAL_INFO             tzplatform_mkpath(tzplatform_getid("TZ_SYS_GLOBALUSER_DATA"), ".voice/tts/personal-info")
 
 
 
index ca92981..df897fa 100755 (executable)
@@ -719,8 +719,6 @@ int ttse_set_activated_mode_changed_cb(ttse_activated_mode_changed_cb callback);
 */
 int ttse_set_personal_tts_id_set_cb(ttse_set_personal_tts_id_cb callback);
 
-int ttse_send_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data);
-
 
 #ifdef __cplusplus
 }
index c5ab4f5..b14c9e5 100644 (file)
@@ -199,12 +199,9 @@ mkdir -p -m 0775 %{TZ_SYS_GLOBALUSER_DATA}/.voice
 chsmack -t %{TZ_SYS_GLOBALUSER_DATA}/.voice
 chsmack -a "User::App::Shared" %{TZ_SYS_GLOBALUSER_DATA}/.voice
 mkdir -p %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/engine-info
-mkdir -p -m 0775 %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/personal-info
 chsmack -a "User::App::Shared" %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts
 chsmack -t %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/engine-info
-chsmack -t %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/personal-info
 chsmack -a "User::App::Shared" %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/engine-info
-chsmack -a "User::App::Shared" %{TZ_SYS_GLOBALUSER_DATA}/.voice/tts/personal-info
 chown -R ui_fw:users %{TZ_SYS_GLOBALUSER_DATA}/.voice
 
 %postun -p /sbin/ldconfig
index 3530106..3743d53 100644 (file)
@@ -260,20 +260,3 @@ int ttsd_config_set_instant_reprepare_client(const unsigned int uid)
 
        return TTSD_ERROR_NONE;
 }
-
-int ttsd_config_update_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data)
-{
-       char* engine_id = NULL;
-       // if (0 != tts_config_mgr_get_engine(&engine_id)) {
-       //      SLOG(LOG_ERROR, tts_tag(), "[Config ERROR] Fail to get engine id");
-       //      return TTSD_ERROR_OPERATION_FAILED;
-       // }
-
-       int ret = tts_config_mgr_update_personal_voice(engine_id, language, unique_id, display_name, device_name);
-       if (0 != ret) {
-               SLOG(LOG_ERROR, tts_tag(), "[Config ERROR] Fail to update personal voice to xml");
-               return TTSD_ERROR_OPERATION_FAILED;
-       }
-
-       return 0;
-}
index 70097e0..b1a8bb6 100644 (file)
@@ -58,8 +58,6 @@ int ttsd_config_get_instant_reprepare_client(unsigned int *uid);
 
 int ttsd_config_set_instant_reprepare_client(const unsigned int uid);
 
-int ttsd_config_update_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data);
-
 #ifdef __cplusplus
 }
 #endif
index 757b049..61ff6bd 100644 (file)
@@ -1621,18 +1621,6 @@ int ttsd_set_personal_tts_id_set_cb(ttse_set_personal_tts_id_cb callback)
        return ret;
 }
 
-int ttsd_send_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data)
-{
-       SLOG(LOG_DEBUG, tts_tag(), "[Server] Set private data requested cb");
-
-       int ret = ttsd_config_update_personal_voice(language, unique_id, display_name, device_name, NULL);
-       if (0 != ret) {
-               SLOG(LOG_ERROR, tts_tag(), "[Server ERROR] Fail to update personal voice");
-       }
-
-       return ret;
-}
-
 int ttsd_server_play_pcm(unsigned int uid)
 {
        app_tts_state_e state = ttsd_data_get_client_state(uid);
index d7d9afe..ea20c7b 100644 (file)
@@ -45,8 +45,6 @@ int ttsd_set_activated_mode_changed_cb(ttse_activated_mode_changed_cb callback);
 
 int ttsd_set_personal_tts_id_set_cb(ttse_set_personal_tts_id_cb callback);
 
-int ttsd_send_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data);
-
 
 /*
 * Server API for client
index 2472ce4..67a159b 100755 (executable)
@@ -121,18 +121,6 @@ static bool __is_test_app()
        return is_test_app;
 }
 
-int ttse_send_personal_voice(const char* language, const char* unique_id, const char* display_name, const char* device_name, void* user_data)
-{
-       SLOG(LOG_INFO, tts_tag(), "[INFO] TTS Engine send personal voices list : language(%s), unique_id(%s), display_name(%s), device_name(%s)", language, unique_id, display_name, device_name);
-
-       int ret = ttsd_send_personal_voice(language, unique_id, display_name, device_name, NULL);
-       if (0 != ret) {
-               SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to send personal voice");
-       }
-
-       return TTSE_ERROR_NONE;
-}
-
 int ttse_main(int argc, char** argv, ttse_request_callback_s *callback)
 {
        if (false == is_feature_enabled()) {