axiolid_measure/measure.rs
1//! Open measurement capability.
2
3use axiolid_core::Tolerance;
4
5use crate::MassProperties;
6
7/// Compute mass properties for one representation type.
8pub trait Measure<T>: core::fmt::Debug + Send + Sync {
9 /// Structured failure (open shell, self intersection, unsupported shape).
10 type Error: std::error::Error + Send + Sync + 'static;
11
12 /// Measure under an explicit geometric tolerance.
13 fn measure(&self, value: &T, tolerance: Tolerance) -> Result<MassProperties, Self::Error>;
14}