use serde::Deserialize;
#[derive(Deserialize, Debug)]
pub(crate) struct Configuration {
pub(crate) p4_devices: Vec<DeviceConfig>,
}
#[derive(Deserialize, Debug)]
pub(crate) struct DeviceConfig {
#[serde(alias = "device-id")]
#[allow(dead_code)]
pub(crate) device_id: u32,
pub(crate) p4_programs: Vec<P4Program>,
}
#[derive(Deserialize, Debug)]
pub(crate) struct P4Program {
#[serde(alias = "program-name")]
pub(crate) program_name: String,
#[serde(alias = "bfrt-config")]
pub(crate) bfrt_config: String,
pub(crate) p4_pipelines: Vec<P4Pipeline>,
}
#[derive(Deserialize, Debug)]
pub(crate) struct P4Pipeline {
pub(crate) p4_pipeline_name: String,
pub(crate) context: String,
pub(crate) config: String,
pub(crate) pipe_scope: Vec<u32>,
}