harmony/harmony/src/infra/intel_amt/mod.rs
Jean-Gabriel Gill-Couture b4cc5cff4f feat: add serde derive to Score types
This commit adds `serde` dependency and derives `Serialize` trait for `Score` types. This is necessary for serialization and deserialization of these types, which is required to display Scores to various user interfaces

- Added `serde` dependency to `harmony_types/Cargo.toml`.
- Added `serde::Serialize` derive macro to `MacAddress` in `harmony_types/src/lib.rs`.
- Added `serde::Serialize` derive macro to `Config` in `opnsense-config/src/config/config.rs`.
- Added `serde::Serialize` derive macro to `Score` in `harmony_types/src/lib.rs`.
- Added `serde::Serialize` derive macro to `Config` and `Score` in relevant modules.
- Added placeholder `todo!()` implementations for `serialize` methods. These will be implemented in future commits.
2025-04-05 14:36:08 -04:00

22 lines
499 B
Rust

use crate::hardware::ManagementInterface;
use derive_new::new;
use harmony_types::net::MacAddress;
use log::info;
use serde::Serialize;
#[derive(new, Serialize)]
pub struct IntelAmtManagement {
mac_address: MacAddress,
}
impl ManagementInterface for IntelAmtManagement {
fn boot_to_pxe(&self) {
info!("Launching boot to pxe for mac address {}", self.mac_address);
todo!()
}
fn get_supported_protocol_names(&self) -> String {
"IntelAMT".to_string()
}
}