return TTSE_ERROR_NONE;
}
-static int __unregister_cb(rpc_port_stub_tts_context_h context, int uid, void* user_data)
-{
- struct client_s *client = NULL;
-
- rpc_port_stub_tts_context_get_tag(context, (void *)&client);
- if (!client)
- return -1;
-
- if (0 != ttsd_data_unset_notify_h(uid)) {
- SLOG(LOG_ERROR, tts_tag(), "[Server ERROR] Fail to unset notify callback");
- return TTSD_ERROR_OPERATION_FAILED;
- }
-
- if (0 != ttsd_data_clear_data(uid)) {
- SLOG(LOG_ERROR, tts_tag(), "[Server ERROR] Failed to remove client");
- return TTSD_ERROR_OPERATION_FAILED;
- }
- rpc_port_stub_tts_context_set_tag(context, NULL);
-
- return TTSE_ERROR_NONE;
-}
-
static int __set_mode_cb(rpc_port_stub_tts_context_h context, int mode, void* user_data)
{
//ttsd_set_mode(mode);
g_callback.set_mode = __set_mode_cb;
g_callback.register_cb = __register_cb;
g_callback.register_cb_sync = __register_cb_sync;
- g_callback.unregister_cb = __unregister_cb;
g_callback.initialize = __initialize_cb;
g_callback.finalize = __finalize_cb;
g_callback.add_text = __add_text_cb;
void notify_cb(int pid, int uid, bundle msg) delegate;
void register_cb(int pid, int uid, notify_cb callback) async;
int register_cb_sync(int pid, int uid, notify_cb callback);
- int unregister_cb(int uid);
int set_mode(int mode);
int initialize(in int pid, in int uid, out bool credential_needed);
int get_private(in int uid, string key, out string priv_data);
int play(int uid, string credential);
int add_pcm(int uid, int event, string pcm_data, int data_size, int audio_type, int rate);
-
}