NetworkManager/src/libnm-core-intern
Thomas Haller c8392018ca
libnm: refactor to-dbus on the client skipping to serialize legacy properties
We have 4 legacy properties ("ipv[46].addresses", "ipv[46].routes") that
got replaced by newer variants ("ipv[46].address-data", "ipv[46].route-data").

When the client side of libnm (_nm_utils_is_manager_process) serializes
those properties, it must only serialize the newer version. That is so
that the forward/backward compatibility works as intended.

Previously, there was the NM_SETTING_PARAM_LEGACY GObject property flag.
That was fine, but not very clear.

For one, the legacy part of those properties is only about D-Bus. In
particular, they are not deprecated in libnm, keyfile, or nmcli. Thus
the name wasn't very clear.

Also, in the meantime we have more elaborate property meta data, that
goes beyond the meta data of the GObject property.

Move NM_SETTING_PARAM_LEGACY to NMSettInfoProperty.to_dbus_only_in_manager_process.
I think, this is a better name. It's also right at

```
     _nm_properties_override_gobj(
         properties_override,
         g_object_class_find_property(G_OBJECT_CLASS(setting_class), NM_SETTING_IP_CONFIG_ROUTES),
         NM_SETT_INFO_PROPERT_TYPE_DBUS(NM_G_VARIANT_TYPE("a(ayuayu)"),
                                        .to_dbus_fcn   = ip6_routes_to_dbus,
                                        .compare_fcn   = _nm_setting_ip_config_compare_fcn_routes,
                                        .from_dbus_fcn = ip6_routes_from_dbus, ),
         .to_dbus_only_in_manager_process = TRUE,
         .dbus_deprecated                 = TRUE, );
```

that is, directly at the place where we describe how the D-Bus property behaves.
2022-10-27 09:11:24 +02:00
..
meson.build build/meson: remove unnecessary libnm_core_intern_dep 2021-02-28 10:42:05 +01:00
nm-core-internal.h libnm: refactor to-dbus on the client skipping to serialize legacy properties 2022-10-27 09:11:24 +02:00
nm-keyfile-internal.h format: reformat source tree with clang-format 13.0 2021-11-29 09:31:09 +00:00
nm-keyfile-utils.h all: drop redundant includes 2022-05-09 19:20:18 +02:00
nm-meta-setting-base-impl.h libnm: add nm_setting_8021x_scheme_vtable_by_setting_key() helper 2022-03-28 18:27:36 +02:00
nm-meta-setting-base.h build: move "libnm-core/" to "src/" and split it 2021-02-18 19:46:51 +01:00
README.md build: move "libnm-core/" to "src/" and split it 2021-02-18 19:46:51 +01:00

libnm-core-intern

This contains header files only, which are also part of the internal API of libnm-core-impl.

libnm-core-impl is a static library that (among others) implements libnm-core-public (which is a part of the public API of libnm). This library gets statically linked into libnm and NetworkManager. Hence, those components can also access internal (but not private) API of libnm-core-impl, and this API is in libnm-core-intern.

These headers can thus be included by anybody who statically links with libnm-core-impl (including libnm-core-impl itself).

The directory should not be added to the include search path, instead users should explicitly #include "libnm-core-intern/nm-core-internal.h")

There is no source code here and no static library to link against.