Updated connman to version 1.35
[platform/upstream/connman.git] / include / service.h
old mode 100644 (file)
new mode 100755 (executable)
index 31dfce7..3055023
 
 #include <stdbool.h>
 
+#if defined TIZEN_EXT
+#include <glib.h>
+#endif
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -79,6 +83,7 @@ enum connman_service_error {
        CONNMAN_SERVICE_ERROR_LOGIN_FAILED  = 5,
        CONNMAN_SERVICE_ERROR_AUTH_FAILED    = 6,
        CONNMAN_SERVICE_ERROR_INVALID_KEY    = 7,
+       CONNMAN_SERVICE_ERROR_BLOCKED        = 8,
 };
 
 enum connman_service_proxy_method {
@@ -129,12 +134,50 @@ bool connman_service_get_favorite(struct connman_service *service);
 bool connman_service_get_autoconnect(struct connman_service *service);
 
 struct connman_service *connman_service_lookup_from_network(struct connman_network *network);
+struct connman_service *connman_service_lookup_from_identifier(const char* identifier);
 
 void connman_service_create_ip4config(struct connman_service *service,
                                                                int index);
 void connman_service_create_ip6config(struct connman_service *service,
                                                                int index);
 
+#if defined TIZEN_EXT
+/*
+ * Description: TIZEN implements system global connection management.
+ *              It's only for PDP (cellular) bearer. Wi-Fi is managed by ConnMan automatically.
+ *              Reference count can help to manage open/close connection requests by each application.
+ */
+
+/*
+ * Increase reference count of user-initiated packet data network connection
+ */
+void connman_service_user_pdn_connection_ref(struct connman_service *service);
+
+/*
+ * Decrease reference count of user initiated packet data network connection
+ * and return TRUE if counter is zero.
+ */
+gboolean connman_service_user_pdn_connection_unref_and_test(
+                                       struct connman_service *service);
+
+/*
+ * Test reference count of user initiated packet data network connection
+ * and return TRUE if counter is zero. No impact to reference count
+ */
+gboolean connman_service_is_no_ref_user_pdn_connection(
+                                       struct connman_service *service);
+#endif
+
+#if defined TIZEN_EXT
+struct connman_service *connman_service_get_default_connection(void);
+
+/*
+ * Description: telephony plug-in requires manual PROXY setting
+ */
+int connman_service_set_proxy(struct connman_service *service,
+                                       const char *proxy, gboolean active);
+#endif
+
 #ifdef __cplusplus
 }
 #endif