#[non_exhaustive]pub enum BodyMeasureError {
EmptyBody {
body: BodySide,
},
Measure(ExactMeasureError),
ItemsOverlap {
body: BodySide,
first: usize,
second: usize,
},
ItemsShareFace {
body: BodySide,
first: usize,
second: usize,
},
ItemsNearlyShareFace {
body: BodySide,
first: usize,
second: usize,
gap: f64,
},
ContactPlaneNotAxisNormal {
body: BodySide,
first: usize,
second: usize,
},
Placement {
body: BodySide,
error: TransformError,
},
}Expand description
Why two bodies of exact solids could not be measured.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
EmptyBody
The body has no items.
Measure(ExactMeasureError)
An item could not be measured, as by the single-solid queries.
ItemsOverlap
Two items of one body were not shown apart or touching (see the module docs): their boundaries may cross, one may lie inside the other, or they touch where no planar face separates them. The boundary of their union is not formed here.
Fields
Two items of one body touch where both have a face in the plane that separates them, and the shared patch cannot be cut exactly: a B-spline face reaches the plane, or a face in contact is bounded by an edge that is neither a line nor a circle.
Two items of one body are within the caller’s tolerance of face
contact without being in exact contact: they interpenetrate by up to
-gap, or their faces are on planes normal to one axis but not at
the same coordinate in their own numbers (a gap or an overlap below
rounding). Gluing them would measure a boundary the items do not
have, so the pair is refused rather than snapped (a certified
positive gap is measured exactly instead: the two faces are on the
union’s boundary).
ContactPlaneNotAxisNormal
Two items of one body touch, to within rounding, where both have
faces on a plane that no coordinate axis is normal to: walls of
items turned against each other, or an assembly placed before it was
measured. Contact is cut only on axis-normal planes, where it can be
shown exact; pass the items in the body’s own frame with the
placement in a PlacedBody instead, so the contact is cut before
the placement turns it.
Fields
Placement
The placement of a PlacedBody is not rigid, or its items cannot
be moved by it.
Trait Implementations§
Source§impl Clone for BodyMeasureError
impl Clone for BodyMeasureError
Source§fn clone(&self) -> BodyMeasureError
fn clone(&self) -> BodyMeasureError
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BodyMeasureError
impl Debug for BodyMeasureError
Source§impl Display for BodyMeasureError
impl Display for BodyMeasureError
Source§impl Error for BodyMeasureError
impl Error for BodyMeasureError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Source§impl From<ExactMeasureError> for BodyMeasureError
impl From<ExactMeasureError> for BodyMeasureError
Source§fn from(error: ExactMeasureError) -> BodyMeasureError
fn from(error: ExactMeasureError) -> BodyMeasureError
Source§impl PartialEq for BodyMeasureError
impl PartialEq for BodyMeasureError
impl StructuralPartialEq for BodyMeasureError
Auto Trait Implementations§
impl Freeze for BodyMeasureError
impl RefUnwindSafe for BodyMeasureError
impl Send for BodyMeasureError
impl Sync for BodyMeasureError
impl Unpin for BodyMeasureError
impl UnsafeUnpin for BodyMeasureError
impl UnwindSafe for BodyMeasureError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more