model: suppress datums and partitions: kept, but left out of the model (#291)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UhhZMBTviDQxZvwnyP89fo
This commit is contained in:
jyvikoandClaude Opus 5.5 authored and Irakli Kourtis committed 2026-10-15 10:17:28 -04:00
1 parent dcf03e3378
commit 5189554a6a
11 files changed
+183 -34

No files matched your search

+4 -1
View File
@@ -226,6 +226,9 @@ impl Model {
for p in &mut self.partitions {
swap(&mut p.datum, from, to);
}
if self.suppressed_datums.remove(from) {
self.suppressed_datums.insert(to.to_string());
}
}
Kind::Section | Kind::Coupling | Kind::Contact | Kind::Tie | Kind::PointMass | Kind::Spring => {}
}
@@ -294,7 +297,7 @@ mod tests {
m.set_load_active("go", "p", true).unwrap();
m.set_load_active("go", "f", true).unwrap();
m.add_datum("d", Datum::Plane { point: [0.0; 3], normal: [0.0, 0.0, 1.0] }).unwrap();
m.add_partition(Partition { name: "half".into(), datum: "d".into(), bodies: Vec::new() }).unwrap();
m.add_partition(Partition { name: "half".into(), datum: "d".into(), bodies: Vec::new(), suppressed: false }).unwrap();
m
}