#[non_exhaustive]pub enum DesignError {
Domain {
what: &'static str,
value: f64,
},
Geometry(String),
UnphysicalInertia(String),
MaterialKind {
part: &'static str,
material: String,
expected: &'static str,
actual: &'static str,
},
Tree {
id: String,
message: String,
},
InComponent {
id: String,
source: Box<DesignError>,
},
DuplicateId(String),
UnknownId {
what: &'static str,
id: String,
},
Numerics(CoreError),
}Expand description
An error from the design model: a dimension outside its domain, geometry that contradicts itself, or mass properties no real body could have.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Domain
An input outside its domain, such as a negative length.
Geometry(String)
Dimensions that contradict each other, such as a wall thicker than the radius.
UnphysicalInertia(String)
An inertia tensor that no real body has.
MaterialKind
A material of the wrong kind for the part, such as a surface density for a solid.
Fields
Tree
A design tree that doesn’t hold together, such as fins attached to an inner tube or an automatic radius with nothing to take it from.
Fields
InComponent
An error in one stage or component, with its id.
DuplicateId(String)
Two stages, components or configurations share an id, or an id is empty.
UnknownId
A reference to an id that doesn’t exist.
Numerics(CoreError)
A numerical method failed, such as an integral that didn’t converge.
Trait Implementations§
Source§impl Clone for DesignError
impl Clone for DesignError
Source§fn clone(&self) -> DesignError
fn clone(&self) -> DesignError
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 DesignError
impl Debug for DesignError
Source§impl Display for DesignError
impl Display for DesignError
Source§impl Error for DesignError
impl Error for DesignError
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<CoreError> for DesignError
impl From<CoreError> for DesignError
Source§impl PartialEq for DesignError
impl PartialEq for DesignError
Source§fn eq(&self, other: &DesignError) -> bool
fn eq(&self, other: &DesignError) -> bool
self and other values to be equal, and is used by ==.