Initialize Tizen 2.3
[framework/connectivity/mobileap-agent.git] / include / mobileap_wifi.h
1 /*
2  * mobileap-agent
3  * Copyright (c) 2012 Samsung Electronics Co., Ltd.
4  *
5  * Licensed under the Apache License, Version 2.0 (the License);
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  *     http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17
18 #ifndef __MOBILEAP_WIFI_H__
19 #define __MOBILEAP_WIFI_H__
20
21 #include "mobileap_agent.h"
22
23 #define SOFTAP_SECURITY_TYPE_OPEN_STR           "open"
24 #define SOFTAP_SECURITY_TYPE_WPA2_PSK_STR       "wpa2-psk"
25 #define SOFTAP_PASSPHRASE_PATH                  "wifi_tethering.txt"
26
27 typedef enum {
28         SOFTAP_SECURITY_TYPE_OPEN,
29         SOFTAP_SECURITY_TYPE_WPA2_PSK,
30 } softap_security_type_e;
31
32 void _register_wifi_station_handler(void);
33 void _add_wifi_device_to_array(softap_device_info_t *di, GPtrArray *array);
34 mobile_ap_error_code_e _disable_wifi_tethering(TetheringObject *obj);
35
36 /* Dbus method */
37 gboolean tethering_enable_wifi_tethering(TetheringObject *obj, gchar *ssid,
38                 gchar *key, gint hide_mode,
39                 DBusGMethodInvocation *context);
40
41 gboolean tethering_disable_wifi_tethering(TetheringObject *obj,
42                 DBusGMethodInvocation *context);
43
44 gboolean tethering_get_wifi_tethering_hide_mode(TetheringObject *obj,
45                 DBusGMethodInvocation *context);
46
47 gboolean tethering_set_wifi_tethering_hide_mode(TetheringObject *obj,
48                 gint hide_mode, DBusGMethodInvocation *context);
49
50 gboolean tethering_get_wifi_tethering_ssid(TetheringObject *obj,
51                 DBusGMethodInvocation *context);
52
53 gboolean tethering_get_wifi_tethering_security_type(TetheringObject *obj,
54                 DBusGMethodInvocation *context);
55
56 gboolean tethering_set_wifi_tethering_security_type(TetheringObject *obj,
57                 gchar *security_type, DBusGMethodInvocation *context);
58
59 gboolean tethering_get_wifi_tethering_passphrase(TetheringObject *obj,
60                 DBusGMethodInvocation *context);
61
62 gboolean tethering_set_wifi_tethering_passphrase(TetheringObject *obj,
63                 gchar *passphrase, guint len, DBusGMethodInvocation *context);
64 #endif /* __MOBILEAP_WIFI_H__ */