summary refs log tree commit diff
path: root/libnm-util/nm-setting-connection.h
diff options
context:
space:
mode:
Diffstat (limited to 'libnm-util/nm-setting-connection.h')
-rw-r--r--libnm-util/nm-setting-connection.h29
1 files changed, 22 insertions, 7 deletions
diff --git a/libnm-util/nm-setting-connection.h b/libnm-util/nm-setting-connection.h
index 1ec5bf12..19874845 100644
--- a/libnm-util/nm-setting-connection.h
+++ b/libnm-util/nm-setting-connection.h
@@ -49,6 +49,8 @@ G_BEGIN_DECLS
  * @NM_SETTING_CONNECTION_ERROR_TYPE_SETTING_NOT_FOUND: the #NMSetting object
  *   referenced by the setting name contained in the
  *   #NMSettingConnection:type property was not present in the #NMConnection
+ * @NM_SETTING_CONNECTION_ERROR_IP_CONFIG_NOT_ALLOWED: ip configuration is not
+ *   allowed to be present.
  *
  * Describes errors that may result from operations involving a
  * #NMSettingConnection.
@@ -56,15 +58,13 @@ G_BEGIN_DECLS
  **/
 typedef enum
 {
-	NM_SETTING_CONNECTION_ERROR_UNKNOWN = 0,
-	NM_SETTING_CONNECTION_ERROR_INVALID_PROPERTY,
-	NM_SETTING_CONNECTION_ERROR_MISSING_PROPERTY,
-	NM_SETTING_CONNECTION_ERROR_TYPE_SETTING_NOT_FOUND
+	NM_SETTING_CONNECTION_ERROR_UNKNOWN = 0,            /*< nick=UnknownError >*/
+	NM_SETTING_CONNECTION_ERROR_INVALID_PROPERTY,       /*< nick=InvalidProperty >*/
+	NM_SETTING_CONNECTION_ERROR_MISSING_PROPERTY,       /*< nick=MissingProperty >*/
+	NM_SETTING_CONNECTION_ERROR_TYPE_SETTING_NOT_FOUND, /*< nick=TypeSettingNotFound >*/
+	NM_SETTING_CONNECTION_ERROR_IP_CONFIG_NOT_ALLOWED,  /*< nick=IpConfigNotAllowed >*/
 } NMSettingConnectionError;
 
-#define NM_TYPE_SETTING_CONNECTION_ERROR (nm_setting_connection_error_get_type ()) 
-GType nm_setting_connection_error_get_type (void);
-
 #define NM_SETTING_CONNECTION_ERROR nm_setting_connection_error_quark ()
 GQuark nm_setting_connection_error_quark (void);
 
@@ -75,6 +75,16 @@ GQuark nm_setting_connection_error_quark (void);
 #define NM_SETTING_CONNECTION_TIMESTAMP   "timestamp"
 #define NM_SETTING_CONNECTION_READ_ONLY   "read-only"
 #define NM_SETTING_CONNECTION_PERMISSIONS "permissions"
+#define NM_SETTING_CONNECTION_ZONE        "zone"
+#define NM_SETTING_CONNECTION_MASTER      "master"
+#define NM_SETTING_CONNECTION_SLAVE_TYPE  "slave-type"
+
+/* Well-known zone names */
+#define NM_SETTING_CONNECTION_ZONE_TRUSTED   "trusted"
+#define NM_SETTING_CONNECTION_ZONE_HOME      "home"
+#define NM_SETTING_CONNECTION_ZONE_WORK      "work"
+#define NM_SETTING_CONNECTION_ZONE_PUBLIC    "public"
+#define NM_SETTING_CONNECTION_ZONE_BLOCK     "block"
 
 /**
  * NMSettingConnection:
@@ -112,6 +122,7 @@ gboolean    nm_setting_connection_get_permission       (NMSettingConnection *set
                                                         const char **out_ptype,
                                                         const char **out_pitem,
                                                         const char **out_detail);
+const char *nm_setting_connection_get_zone             (NMSettingConnection *setting);
 gboolean    nm_setting_connection_permissions_user_allowed (NMSettingConnection *setting, const char *uname);
 gboolean    nm_setting_connection_add_permission       (NMSettingConnection *setting,
                                                         const char *ptype,
@@ -119,6 +130,10 @@ gboolean    nm_setting_connection_add_permission       (NMSettingConnection *set
                                                         const char *detail);
 void        nm_setting_connection_remove_permission    (NMSettingConnection *setting,
                                                         guint32 idx);
+const char *nm_setting_connection_get_master           (NMSettingConnection *setting);
+gboolean    nm_setting_connection_is_slave_type        (NMSettingConnection *setting,
+							const char *type);
+const char *nm_setting_connection_get_slave_type       (NMSettingConnection *setting);
 
 G_END_DECLS