Update project structure and configurations

This commit is contained in:
2026-05-23 10:19:55 +02:00
parent ab5dc7e568
commit 62efea0646
1832 changed files with 83568 additions and 51829 deletions

View File

@@ -712,6 +712,32 @@ impl Component for ExpansionValve<Connected> {
fn set_calib_indices(&mut self, indices: entropyk_core::CalibIndices) {
self.calib_indices = indices;
}
fn signature(&self) -> String {
format!(
"ExpansionValve(fluid={}, circuit={})",
self.fluid_id.as_str(),
self.circuit_id.0
)
}
fn to_params(&self) -> crate::ComponentParams {
crate::ComponentParams::new("ExpansionValve")
.with_param("fluid", self.fluid_id.as_str())
.with_param("circuitId", self.circuit_id.0)
.with_param("opening", self.opening)
.with_param("calib", serde_json::to_value(&self.calib).unwrap_or(serde_json::Value::Null))
}
fn update_calib_factor(&mut self, factor: &str, value: f64) -> bool {
let mut c = self.calib().clone();
if c.set_factor(factor, value) {
self.set_calib(c);
true
} else {
false
}
}
}
use crate::state_machine::StateManageable;