release tizen_2.0 beta
[framework/telephony/tel-plugin-socket_communicator.git] / libclient / include / tapi_sipc.h
1 /*
2  * tel-plugin-socket-communicator
3  *
4  * Copyright (c) 2012 Samsung Electronics Co., Ltd. All rights reserved.
5  *
6  * Contact: Ja-young Gu <jygu@samsung.com>
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20
21 #ifndef __TAPI_SIPC_H__
22 #define __TAPI_SIPC_H__
23
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27
28 #include <tapi_type.h>
29
30 tapi_handle_t*  tapi_init( char *app_name, char *cp_name );
31 gboolean                tapi_deinit( tapi_handle_t *h );
32 gboolean                tapi_register_notification( tapi_handle_t *h, tapi_service_notification_e noti, tapi_cb cb, void *cb_data);
33
34 tapi_service_object_t* tapi_create_service_object(tapi_service_command_e cmd);
35 gboolean                tapi_service_object_add_data(tapi_service_object_t* obj, const gchar* key, void *in_data, tapi_object_data_type_e type);
36 gboolean                tapi_service_object_get_data(const tapi_service_object_t* obj, const gchar* key, void **out_data, tapi_object_data_type_e type);
37 gchar                   tapi_service_object_get_char(const tapi_service_object_t* obj, const gchar* key);
38 gboolean                tapi_service_object_get_boolean(const tapi_service_object_t* obj, const gchar* key);
39 gint                    tapi_service_object_get_int(const tapi_service_object_t* obj, const gchar* key);
40 gdouble                 tapi_service_object_get_double(const tapi_service_object_t* obj, const gchar* key);
41 gchar*                  tapi_service_object_get_string(const tapi_service_object_t* obj, const gchar* key);
42 tapi_service_command_e tapi_service_object_get_command(const struct _tapi_service_object* obj);
43 tapi_service_object_t* tapi_service_object_get_object(const tapi_service_object_t* obj, const gchar* key);
44 gboolean                tapi_service_object_remove_data(tapi_service_object_t* obj, const gchar* key);
45 gboolean                tapi_service_object_remove_alldata(tapi_service_object_t* obj);
46 gboolean                tapi_service_object_destory(tapi_service_object_t* obj);
47
48 gboolean                tel_processing_command_sync(tapi_handle_t *h, tapi_service_object_t* in_obj, tapi_service_object_t* out_obj);
49 gboolean                tel_processing_command_async(tapi_handle_t *h, tapi_service_object_t* in_obj, tapi_cb cb, void *user_data);
50
51 #ifdef __cplusplus
52 }
53 #endif
54
55 #endif