2 * Copyright (c) 2016 Samsung Electronics Co., Ltd. All rights reserved.
4 * Contact: Suresh Kumar N (suresh.n@samsung.com)
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
19 #ifndef __ZIGBEE_LIB_SERVICE_H__
20 #define __ZIGBEE_LIB_SERVICE_H__
22 ZigBeeService *zblib_service_new();
23 void zblib_service_free(ZigBeeService *service);
25 gboolean zblib_service_run(ZigBeeService *service);
26 gboolean zblib_service_exit(ZigBeeService *service);
28 gboolean zblib_service_add_plugin(ZigBeeService *service, ZigBeePlugin *plugin);
29 gboolean zblib_service_remove_plugin(ZigBeeService *service, ZigBeePlugin *plugin);
31 gboolean zblib_service_load_plugins(ZigBeeService *service, const char *plugin_path);
32 gboolean zblib_service_initialize_plugins(ZigBeeService *service);
33 gboolean zblib_service_unload_plugins(ZigBeeService *service);
35 GSList *zblib_service_ref_plugins(ZigBeeService *service);
37 gboolean zblib_service_add_service_interface(ZigBeeService *service,
38 ZigBeeServiceInterface *service_interface);
39 gboolean zblib_service_remove_service_interface(ZigBeeService *service,
40 ZigBeeServiceInterface *service_interface);
42 ZigBeeServiceInterface *zblib_service_ref_service_interface(ZigBeeService *service,
43 const gchar *service_interface_name);
45 GHashTable *zblib_service_ref_request_hash_table(ZigBeeService *service);
46 gint zblib_service_generate_request_id(ZigBeeService *service);
48 gboolean zblib_service_dispatch_request(ZigBeeService *service,
50 void zblib_service_send_response(ZigBeeService *service,
51 guint request_id, gpointer resp_data, guint resp_data_len);
53 #endif /* __ZIGBEE_LIB_SERVICE_H__ */