pub enum SmoothError {
NonFiniteInput,
NegativeInput,
DegenerateAxis,
InvalidAngle,
TooFewPoints,
DegenerateFrame,
ConcaveFrame,
SelfIntersectingFrame,
}Expand description
几何计算错误。
Variants§
NonFiniteInput
输入包含 NaN 或不允许的无穷值。
NegativeInput
长度、半径或限制为负数。
DegenerateAxis
角点方向向量长度过小。
InvalidAngle
角点夹角不在开区间 (0, PI) 内。
TooFewPoints
闭合 frame 少于 3 个点。
DegenerateFrame
frame 包含退化边、共线点或面积为零。
ConcaveFrame
frame 存在凹角,当前版本暂不支持。
SelfIntersectingFrame
frame 存在自相交边。
Trait Implementations§
Source§impl Clone for SmoothError
impl Clone for SmoothError
Source§fn clone(&self) -> SmoothError
fn clone(&self) -> SmoothError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SmoothError
impl Debug for SmoothError
Source§impl Display for SmoothError
impl Display for SmoothError
Source§impl Error for SmoothError
impl Error for SmoothError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl PartialEq for SmoothError
impl PartialEq for SmoothError
Source§fn eq(&self, other: &SmoothError) -> bool
fn eq(&self, other: &SmoothError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for SmoothError
impl Eq for SmoothError
impl StructuralPartialEq for SmoothError
Auto Trait Implementations§
impl Freeze for SmoothError
impl RefUnwindSafe for SmoothError
impl Send for SmoothError
impl Sync for SmoothError
impl Unpin for SmoothError
impl UnsafeUnpin for SmoothError
impl UnwindSafe for SmoothError
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