about summary refs log tree commit diff
path: root/libnm-util/nm-setting-private.h
diff options
context:
space:
mode:
Diffstat (limited to 'libnm-util/nm-setting-private.h')
-rw-r--r--libnm-util/nm-setting-private.h40
1 files changed, 33 insertions, 7 deletions
diff --git a/libnm-util/nm-setting-private.h b/libnm-util/nm-setting-private.h
index c3ec9d19..1b271d0c 100644
--- a/libnm-util/nm-setting-private.h
+++ b/libnm-util/nm-setting-private.h
@@ -15,13 +15,12 @@
  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  * Boston, MA 02110-1301 USA.
  *
- * (C) Copyright 2011 Red Hat, Inc.
+ * Copyright 2011 Red Hat, Inc.
  */
 
 #ifndef NM_SETTING_PRIVATE_H
 #define NM_SETTING_PRIVATE_H
 
-#include "nm-setting.h"
 #include "nm-glib-compat.h"
 
 #define NM_SETTING_SECRET_FLAGS_ALL \
@@ -30,6 +29,22 @@
 	 NM_SETTING_SECRET_FLAG_NOT_SAVED | \
 	 NM_SETTING_SECRET_FLAG_NOT_REQUIRED)
 
+/**
+ * NMSettingVerifyResult:
+ * @NM_SETTING_VERIFY_SUCCESS: the setting verifies successfully
+ * @NM_SETTING_VERIFY_ERROR: the setting has a serious misconfiguration
+ * @NM_SETTING_VERIFY_NORMALIZABLE: the setting is valid but has properties
+ * that should be normalized
+ * @NM_SETTING_VERIFY_NORMALIZABLE_ERROR: the setting is invalid but the
+ * errors can be fixed by nm_connection_normalize().
+ */
+typedef enum {
+	NM_SETTING_VERIFY_SUCCESS       = TRUE,
+	NM_SETTING_VERIFY_ERROR         = FALSE,
+	NM_SETTING_VERIFY_NORMALIZABLE  = 2,
+	NM_SETTING_VERIFY_NORMALIZABLE_ERROR = 3,
+} NMSettingVerifyResult;
+
 void _nm_register_setting (const char *name,
                            const GType type,
                            const guint32 priority,
@@ -40,10 +55,13 @@ void _nm_register_setting (const char *name,
 
 gboolean _nm_setting_is_base_type (NMSetting *setting);
 gboolean _nm_setting_type_is_base_type (GType type);
+guint32 _nm_setting_get_setting_priority (NMSetting *setting);
 GType _nm_setting_lookup_setting_type (const char *name);
 GType _nm_setting_lookup_setting_type_by_quark (GQuark error_quark);
 gint _nm_setting_compare_priority (gconstpointer a, gconstpointer b);
 
+gboolean _nm_setting_get_property (NMSetting *setting, const char *name, GValue *value);
+
 typedef enum NMSettingUpdateSecretResult {
 	NM_SETTING_UPDATE_SECRET_ERROR              = FALSE,
 	NM_SETTING_UPDATE_SECRET_SUCCESS_MODIFIED   = TRUE,
@@ -87,10 +105,18 @@ static void __attribute__((constructor)) register_setting (void) \
 
 NMSetting *nm_setting_find_in_list (GSList *settings_list, const char *setting_name);
 
-/* Private NMSettingIP4Config methods */
-#include "nm-setting-ip4-config.h"
-const char *nm_setting_ip4_config_get_address_label      (NMSettingIP4Config *setting, guint32 i);
-gboolean    nm_setting_ip4_config_add_address_with_label (NMSettingIP4Config *setting, NMIP4Address *address, const char *label);
+NMSettingVerifyResult _nm_setting_verify_deprecated_virtual_iface_name (const char *interface_name,
+                                                                        gboolean allow_missing,
+                                                                        const char *setting_name,
+                                                                        const char *setting_property,
+                                                                        GQuark error_quark,
+                                                                        gint e_invalid_property,
+                                                                        gint e_missing_property,
+                                                                        GSList *all_settings,
+                                                                        GError **error);
 
-#endif  /* NM_SETTING_PRIVATE_H */
+NMSettingVerifyResult _nm_setting_verify (NMSetting *setting,
+                                          GSList    *all_settings,
+                                          GError    **error);
 
+#endif  /* NM_SETTING_PRIVATE_H */