use crate::addressing::{Dhcp4ConfigV1, Dhcp6ConfigV1, RouteV1, StaticConfigV1}; use crate::bonding::{BondModeV1, BondMonitoringConfigV1}; use crate::interface_id::{InterfaceId, InterfaceName}; #[cfg(test)] use serde::Deserialize; // Builder unit tests deserialize config to this struct, but we never expect to do that otherwise so put // the Deserialize derive behind the test attribute #[cfg_attr(test, derive(Deserialize))] #[derive(Debug)] pub(crate) struct NetworkDBond { pub(crate) name: InterfaceName, pub(crate) dhcp4: Option, pub(crate) dhcp6: Option, pub(crate) static4: Option, pub(crate) static6: Option, pub(crate) routes: Option>, pub(crate) mode: BondModeV1, #[cfg_attr(test, serde(rename = "min-links"))] pub(crate) min_links: Option, pub(crate) monitoring_config: BondMonitoringConfigV1, pub(crate) interfaces: Vec, }