Top |
NMSetting * | nm_setting_user_new () |
const char *const * | nm_setting_user_get_keys () |
const char * | nm_setting_user_get_data () |
gboolean | nm_setting_user_set_data () |
gboolean | nm_setting_user_check_key () |
gboolean | nm_setting_user_check_val () |
The NMSettingUser object is a NMSetting subclass that allow to attach arbitrary user data to NMConnection objects.
NMSetting *
nm_setting_user_new (void
);
Creates a new NMSettingUser object with default values.
const char *const * nm_setting_user_get_keys (NMSettingUser *setting
,guint *out_len
);
a
NULL
-terminated array containing each key from the table.
[array length=out_len][transfer none]
const char * nm_setting_user_get_data (NMSettingUser *setting
,const char *key
);
Since: 1.8
gboolean nm_setting_user_set_data (NMSettingUser *setting
,const char *key
,const char *val
,GError **error
);
setting |
the NMSettingUser instance |
|
key |
the key to set |
|
val |
the value to set or |
[allow-none] |
error |
optional error argument. |
[allow-none] |
TRUE
if the operation was successful. The operation
can fail if key
or val
are not valid strings according
to nm_setting_user_check_key()
and nm_setting_user_check_val()
.
Since: 1.8
gboolean nm_setting_user_check_key (const char *key
,GError **error
);
Checks whether key
is a valid user data key. This means,
key is not NULL
, not too large and valid ASCII. Also,
only digits and numbers are allowed with a few special
characters. The key must contain at least one '.' and
look like a fully qualified DNS name.
Since: 1.8