pub enum ShapeError {
NonPositiveDensity,
DegenerateShape,
MassNotRepresentable,
}Expand description
Why a shape could not become a body.
Variants§
NonPositiveDensity
The density is zero or negative: the body would have no mass.
DegenerateShape
A dimension is zero or negative, or a torus’s tube is at least as wide as its ring: the solid is flat or does not exist.
MassNotRepresentable
The mass or the inertia is too large for Fix128, whose arithmetic wraps:
a body built from the wrapped numbers would be silently wrong.
Trait Implementations§
Source§impl Clone for ShapeError
impl Clone for ShapeError
impl Copy for ShapeError
Source§impl Debug for ShapeError
impl Debug for ShapeError
impl Eq for ShapeError
Source§impl PartialEq for ShapeError
impl PartialEq for ShapeError
impl StructuralPartialEq for ShapeError
Auto Trait Implementations§
impl Freeze for ShapeError
impl RefUnwindSafe for ShapeError
impl Send for ShapeError
impl Sync for ShapeError
impl Unpin for ShapeError
impl UnsafeUnpin for ShapeError
impl UnwindSafe for ShapeError
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
Mutably borrows from an owned value. Read more
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> ⓘ
Converts
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> ⓘ
Converts
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