4 * Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
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.
20 #ifndef _BT_SERVICE_ADAPTER_H_
21 #define _BT_SERVICE_ADAPTER_H_
24 #include <sys/types.h>
25 #include "bluetooth-api.h"
38 int _bt_enable_adapter(void);
40 int _bt_disable_adapter(void);
42 int _bt_reset_adapter(void);
44 void _bt_handle_adapter_added(void);
46 void _bt_handle_adapter_removed(void);
48 int _bt_check_adapter(int *status);
50 void *_bt_get_adapter_agent(void);
52 void _bt_set_discovery_status(gboolean mode);
54 int _bt_get_local_address(bluetooth_device_address_t *local_address);
56 int _bt_get_local_name(bluetooth_device_name_t *local_name);
58 int _bt_set_local_name(char *local_name);
60 int _bt_is_service_used(char *service_uuid, gboolean *used);
62 int _bt_get_discoverable_mode(int *mode);
64 int _bt_set_discoverable_mode(int discoverable_mode, int timeout);
66 int _bt_start_discovery(void);
68 int _bt_cancel_discovery(void);
70 int _bt_get_bonded_devices(GArray **dev_list);
72 int _bt_get_bonded_device_info(bluetooth_device_address_t *device_address,
73 bluetooth_device_info_t *dev_info);
75 int _bt_get_timeout_value(int *timeout);
77 gboolean _bt_is_discovering(void);
79 gboolean _bt_get_cancel_by_user(void);
81 void _bt_set_cancel_by_user(gboolean value);
83 gboolean _bt_get_discovering_property(void);
85 unsigned int _bt_get_discoverable_timeout_property(void);
87 void _bt_adapter_set_status(bt_status_t status);
89 bt_status_t _bt_adapter_get_status(void);
91 void _bt_handle_flight_mode_noti(void);
93 int _bt_get_remote_found_devices(GArray **dev_list);
97 #endif /* __cplusplus */
98 #endif /*_BT_SERVICE_ADAPTER_H_*/