From c333f062ddcba9b35330647bf6cbd0a07f2d786e Mon Sep 17 00:00:00 2001
From: Michael Biebl Removes the NMSetting with the given GType from the NMConnection. This
+ Removes the NMSetting with the given GType from the NMConnection. This
operation dereferences the NMSetting object. the GType of the setting object to remove the GType of the setting object to remove Gets the NMSetting with the given GType, if one has been previously added
+ Gets the NMSetting with the given GType, if one has been previously added
to the NMConnection. setting_type the GType of the setting object to return the GType of the setting object to return the NMSetting, or the NMSetting, or [transfer none] the NMSetting, or the NMSetting, or [transfer none] Converts the NMConnection into a GVariant of type
+ Converts the NMConnection into a GVariant of type
a new floating GVariant describing the connection,
+ a new floating GVariant describing the connection,
its settings, and each setting's properties. [transfer none] Replaces new_settings a GVariant of type a GVariant of type error location to store error, or location to store error, or Compares two NMConnection objects for similarity, with comparison behavior
modified by a set of flags. See Validates the connection and all its settings. Each setting's properties
have allowed values, and some values are dependent on other values. For
example, if a Wi-Fi connection is security enabled, the NMSettingWireless
@@ -968,7 +976,7 @@ setting object's 'security' property must contain the setting name of the
NMSettingWirelessSecurity object, which must also be present in the
connection for the connection to be valid. As another example, the
NMSettingWired object's 'mac-address' property must be a validly formatted
-MAC address. The returned GError contains information about which
+MAC address. The returned GError contains information about which
setting and which property failed validation, and how it failed validation. error location to store error, or location to store error, or Verifies the secrets in the connection. error location to store error, or location to store error, or Since: 1.2 Does some basic normalization and fixup of well known inconsistencies
and deprecated fields. If the connection was modified in any way,
the output parameter Finally the connection will be verified and Finally the connection will be verified and parameters a GHashTable with
+ a GHashTable with
normalization parameters to allow customization of the normalization by providing
specific arguments. Unknown arguments will be ignored and the default will be
-used. The keys must be strings, hashed by error location to store error, or location to store error, or
-GVariant *
+GVariant *
nm_connection_to_dbus ()
@@ -82,7 +82,7 @@
-gboolean
+gboolean
nm_connection_replace_settings ()
@@ -106,7 +106,7 @@
-gboolean
+gboolean
nm_connection_compare ()
@@ -114,7 +114,7 @@
-gboolean
+gboolean
nm_connection_diff ()
@@ -122,7 +122,7 @@
-gboolean
+gboolean
nm_connection_verify ()
@@ -130,7 +130,7 @@
-gboolean
+gboolean
nm_connection_verify_secrets ()
@@ -138,7 +138,7 @@
-gboolean
+gboolean
nm_connection_normalize ()
@@ -169,7 +169,7 @@
-gboolean
+gboolean
nm_connection_update_secrets ()
@@ -199,7 +199,7 @@
-gboolean
+gboolean
nm_connection_is_type ()
@@ -244,7 +244,7 @@
-gboolean
+gboolean
nm_connection_is_virtual ()
@@ -340,6 +340,14 @@
+
+NMSettingDummy *
+
+
+nm_connection_get_setting_dummy ()
+
+
+
NMSettingGeneric *
@@ -388,7 +396,7 @@
@@ -646,8 +654,8 @@ operation dereferences the
-NMSettingMacsec *
+NMSettingMacsec *
nm_connection_get_setting_macsec ()
@@ -558,7 +566,7 @@
@@ -615,8 +623,8 @@ the setting object's reference count.
-nm_connection_remove_setting ()
void
nm_connection_remove_setting (
-NMConnection *connection,
- GType setting_type);GType setting_type);
+
+
nm_connection_get_setting ()
NMSetting *
nm_connection_get_setting (
-NMConnection *connection,
- GType setting_type);GType setting_type);
+Parameters
@@ -665,7 +673,7 @@ to the
@@ -673,7 +681,7 @@ to the
-
+
Returns
-NULL if no setting of that type was previously
+NULL if no setting of that type was previously
added to the NMConnection. Returns
-NULL if no setting with that name was previously
+NULL if no setting with that name was previously
added to the NMConnection. nm_connection_to_dbus ()
-GVariant *
+
GVariant *
nm_connection_to_dbus (
-NMConnection *connection,
NMConnectionSerializationFlags flags);NM_VARIANT_TYPE_CONNECTION describing the connection, suitable for
marshalling over D-Bus or otherwise serializing.Returns
-
nm_connection_replace_settings ()
-gboolean
+
gboolean
nm_connection_replace_settings (
+ NMConnection *connection,
- GVariant *new_settings,
- GError **error);GVariant *new_settings,
+ GError **error);connection
's settings with new_settings
(which must be
@@ -781,12 +789,12 @@ need to result in a connection that passes
+NM_VARIANT_TYPE_CONNECTION, with the new settingsNM_VARIANT_TYPE_CONNECTION, with the new settings
@@ -794,7 +802,7 @@ need to result in a connection that passes
-
+NULLNULL
Returns
-TRUE if connection was updated, FALSE if new_settings
+TRUE if connection was updated, FALSE if new_settings
could not
be deserialized (in which case connection
will be unchanged).
nm_connection_compare ()
-gboolean
+
gboolean
nm_connection_compare (
@@ -897,17 +905,17 @@ each flag's behavior.
NMConnection *a,
NMConnection *b,
NMSettingCompareFlags flags);
nm_connection_diff ()
-gboolean
+
gboolean
nm_connection_diff (
+ NMConnection *a,
NMConnection *b,
NMSettingCompareFlags flags,
- GHashTable **out_settings);GHashTable **out_settings);nm_setting_compare() for a description of
each flag's behavior. If the connections differ, settings and keys within
@@ -951,16 +959,16 @@ differ mapped to one or more of
Returns
-TRUE if the connections contain the same values, FALSE if they do
+TRUE if the connections contain the same values, FALSE if they do
not
nm_connection_verify ()
-gboolean
+
gboolean
nm_connection_verify (
+ NMConnection *connection,
- GError **error);GError **error);Parameters
@@ -986,7 +994,7 @@ setting and which property failed validation, and how it failed validation.
@@ -994,15 +1002,15 @@ setting and which property failed validation, and how it failed validation.
-
+NULLNULL
nm_connection_verify_secrets ()
-gboolean
+
gboolean
nm_connection_verify_secrets (
+ NMConnection *connection,
- GError **error);GError **error);Parameters
@@ -1020,7 +1028,7 @@ nm_connection_verify_secrets (
+NULLNULL
@@ -1028,23 +1036,23 @@ nm_connection_verify_secrets (
Returns
-TRUE if the secrets are valid, FALSE if they are notTRUE if the secrets are valid, FALSE if they are not
nm_connection_normalize ()
-gboolean
+
gboolean
nm_connection_normalize (
+ NMConnection *connection,
- GHashTable *parameters,
- gboolean *modified,
- GError **error);GHashTable *parameters,
+ gboolean *modified,
+ GError **error);modified
- is set TRUE.TRUE returns if the connection
+ is set TRUE.TRUE returns if the connection
is valid. As this function only performs some specific normalization steps
it cannot repair all connections. If the connection has errors that
cannot be normalized, the connection will not be modified.
@@ -1078,7 +1086,7 @@ The values are opaque and depend on the parameter name.
-g_str_hash() and g_str_equal() functions.
+used. The keys must be strings, hashed by g_str_hash() and g_str_equal() functions.
The values are opaque and depend on the parameter name. [allow-none][element-type utf8 gpointer]
@@ -1087,7 +1095,7 @@ why the connection is invalid, if the function returns an error.
-NULL. Contains the reason,
+NULL. Contains the reason,
why the connection is invalid, if the function returns an error.
Returns
-TRUE if the connection is valid, FALSE if it is notTRUE if the connection is valid, FALSE if it is not
@@ -1095,7 +1103,7 @@ why the connection is invalid, if the function returns an error.
const char * nm_connection_need_secrets (+NMConnection *connection, -GPtrArray **hints);
GPtrArray **hints);
Returns the name of the first setting object in the connection which would need secrets to make a successful connection. The returned hints are only intended as a guide to what secrets may be required, because in some @@ -1117,10 +1125,10 @@ secrets are needed.
hints
the address of a pointer to a GPtrArray, initialized to NULL, which on
-return points to an allocated GPtrArray containing the property names of
+
the address of a pointer to a GPtrArray, initialized to NULL, which on
+return points to an allocated GPtrArray containing the property names of
secrets of the NMSetting which may be required; the caller owns the array
-and must free the array itself with g_ptr_array_free(), but not free its
+and must free the array itself with g_ptr_array_free(), but not free its
elements.
NMConnection *connection,
NMSettingClearSecretsWithFlagsFn func,
- gpointer user_data);
+ gpointer user_data);
Clears and frees secrets determined by func
.
gboolean +gboolean nm_connection_update_secrets (+NMConnection *connection,const char *setting_name, -GVariant *secrets, -GError **error);GVariant *secrets, +GError **error);
Update the specified setting's secrets, given a dictionary of secrets
intended for that setting (deserialized from D-Bus for example). Will also
extract the given setting's secrets hash if given a connection dictionary.
If setting_name
- is NULL, expects a fully serialized NMConnection as
+ is NULL, expects a fully serialized NMConnection as
returned by nm_connection_to_dbus() and will update all secrets from all
settings contained in secrets
.
secrets
secrets
a GVariant of secrets, of type NM_VARIANT_TYPE_CONNECTION
+
a GVariant of secrets, of type NM_VARIANT_TYPE_CONNECTION
or NM_VARIANT_TYPE_SETTING
error
location to store error, or NULL
location to store error, or NULL
TRUE if the secrets were successfully updated, FALSE if the update
+
TRUE if the secrets were successfully updated, FALSE if the update
failed (tried to update secrets for a setting that doesn't exist, etc)
NMConnection *connection,
const char *path);
Sets the D-Bus path of the connection. This property is not serialized, and -is only for the reference of the caller. Sets the “path” +is only for the reference of the caller. Sets the “path” property.
const char *
nm_connection_get_interface_name (NMConnection *connection);
Returns the interface name as stored in NMSettingConnection:interface_name.
-If the connection contains no NMSettingConnection, it will return NULL.
+If the connection contains no NMSettingConnection, it will return NULL.
For hardware devices and software devices created outside of NetworkManager,
this name is used to match the device. for software devices created by
NetworkManager, this is the name of the created interface.
@@ -1338,13 +1346,13 @@ NetworkManager, this is the name of the created interface.
gboolean +gboolean nm_connection_is_type (NMConnection *connection,const char *type);A convenience function to check if the given
connection@@ -1377,8 +1385,8 @@ property of the connection and matches that against
TRUE if the connection is of the given type
-, FALSE if not
TRUE if the connection is of the given type
+, FALSE if not
void
nm_connection_for_each_setting_value (NMConnection *connection,
NMSettingValueIterFn func,
- gpointer user_data);
+ gpointer user_data);
Iterates over the properties of each NMSetting object in the NMConnection,
calling the supplied user function for each property.
@@ -1524,7 +1532,7 @@ nm_connection_get_connection_type (
nm_connection_is_virtual ()
-gboolean
+gboolean
nm_connection_is_virtual (NMConnection *connection);
Checks if connection
refers to a virtual device (and thus can potentially be
@@ -1579,7 +1587,7 @@ Eg, "VLAN (eth1.1)".
Returns
the name of connection
's device,
-or NULL if connection
+or NULL if connection
is not a virtual connection type.
[transfer full]
@@ -1607,7 +1615,7 @@ nm_connection_get_setting_802_1x (
Returns
- an NMSetting8021x if the connection contains one, otherwise NULL.
+ an NMSetting8021x if the connection contains one, otherwise NULL.
[transfer none]
@@ -1634,7 +1642,7 @@ nm_connection_get_setting_bluetooth (
Returns
- an NMSettingBluetooth if the connection contains one, otherwise NULL.
+ an NMSettingBluetooth if the connection contains one, otherwise NULL.
[transfer none]
@@ -1661,7 +1669,7 @@ nm_connection_get_setting_bond (
Returns
- an NMSettingBond if the connection contains one, otherwise NULL.
+ an NMSettingBond if the connection contains one, otherwise NULL.
[transfer none]
@@ -1688,7 +1696,7 @@ nm_connection_get_setting_team (
Returns
- an NMSettingTeam if the connection contains one, otherwise NULL.
+ an NMSettingTeam if the connection contains one, otherwise NULL.
[transfer none]
@@ -1715,7 +1723,7 @@ nm_connection_get_setting_team_port (
Returns
- an NMSettingTeamPort if the connection contains one, otherwise NULL.
+ an NMSettingTeamPort if the connection contains one, otherwise NULL.
[transfer none]
@@ -1742,7 +1750,7 @@ nm_connection_get_setting_bridge (
Returns
- an NMSettingBridge if the connection contains one, otherwise NULL.
+ an NMSettingBridge if the connection contains one, otherwise NULL.
[transfer none]
@@ -1769,7 +1777,7 @@ nm_connection_get_setting_bridge_port (
Returns
- an NMSettingBridgePort if the connection contains one, otherwise NULL.
+ an NMSettingBridgePort if the connection contains one, otherwise NULL.
[transfer none]
@@ -1796,7 +1804,7 @@ nm_connection_get_setting_cdma (
Returns
- an NMSettingCdma if the connection contains one, otherwise NULL.
+ an NMSettingCdma if the connection contains one, otherwise NULL.
[transfer none]
@@ -1823,7 +1831,7 @@ nm_connection_get_setting_connection (
Returns
- an NMSettingConnection if the connection contains one, otherwise NULL.
+ an NMSettingConnection if the connection contains one, otherwise NULL.
[transfer none]
@@ -1856,6 +1864,34 @@ nm_connection_get_setting_dcb (
+nm_connection_get_setting_dummy ()
+NMSettingDummy *
+nm_connection_get_setting_dummy (NMConnection *connection);
+A shortcut to return any NMSettingDummy the connection might contain.
+
+
+Since: 1.8
+
+
+
nm_connection_get_setting_generic ()
NMSettingGeneric *
nm_connection_get_setting_generic (NMConnection *connection);
@@ -1904,7 +1940,7 @@ nm_connection_get_setting_gsm (
Returns
- an NMSettingGsm if the connection contains one, otherwise NULL.
+ an NMSettingGsm if the connection contains one, otherwise NULL.
[transfer none]
@@ -1931,7 +1967,7 @@ nm_connection_get_setting_infiniband (
Returns
- an NMSettingInfiniband if the connection contains one, otherwise NULL.
+ an NMSettingInfiniband if the connection contains one, otherwise NULL.
[transfer none]
@@ -1958,7 +1994,7 @@ nm_connection_get_setting_ip_tunnel (
Returns
- an NMSettingIPTunnel if the connection contains one, otherwise NULL.
+ an NMSettingIPTunnel if the connection contains one, otherwise NULL.
[transfer none]
Since: 1.2
@@ -1990,7 +2026,7 @@ majority of IPv4-setting-related methods are on that type, not
Returns
an NMSettingIP4Config if the
-connection contains one, otherwise NULL.
+connection contains one, otherwise NULL.
[type NMSettingIP4Config][transfer none]
@@ -2021,16 +2057,16 @@ majority of IPv6-setting-related methods are on that type, not
Returns
an NMSettingIP6Config if the
-connection contains one, otherwise NULL.
+connection contains one, otherwise NULL.
[type NMSettingIP6Config][transfer none]
nm_connection_get_setting_macsec ()
-NMSettingMacsec *
+NMSettingMacsec *
nm_connection_get_setting_macsec (NMConnection *connection);
-A shortcut to return any NMSettingMacsec the connection might contain.
+A shortcut to return any NMSettingMacsec the connection might contain.
Parameters