pub enum ExtensionShapeError {
InputOutOfBounds {
family_id: &'static str,
input: usize,
input_count: usize,
},
AxisOutOfBounds {
family_id: &'static str,
input: usize,
axis: usize,
rank: usize,
},
RankMismatch {
family_id: &'static str,
lhs_input: usize,
lhs_rank: usize,
rhs_input: usize,
rhs_rank: usize,
},
}Expand description
Errors produced while extension shape requirements inspect input metadata.
§Examples
use tenferro_ops::ExtensionShapeError;
let error = ExtensionShapeError::InputOutOfBounds {
family_id: "example.v1",
input: 2,
input_count: 1,
};
assert!(error.to_string().contains("example.v1"));Variants§
InputOutOfBounds
An input metadata index was outside the supplied input list.
Fields
AxisOutOfBounds
An axis was outside the selected input’s rank.
Fields
RankMismatch
Two inputs required to have the same shape had different ranks.
Trait Implementations§
Source§impl Clone for ExtensionShapeError
impl Clone for ExtensionShapeError
Source§fn clone(&self) -> ExtensionShapeError
fn clone(&self) -> ExtensionShapeError
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 ExtensionShapeError
impl Debug for ExtensionShapeError
Source§impl Display for ExtensionShapeError
impl Display for ExtensionShapeError
Source§impl Error for ExtensionShapeError
impl Error for ExtensionShapeError
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 From<ExtensionShapeError> for Error
impl From<ExtensionShapeError> for Error
Source§fn from(error: ExtensionShapeError) -> Self
fn from(error: ExtensionShapeError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for ExtensionShapeError
impl PartialEq for ExtensionShapeError
Source§fn eq(&self, other: &ExtensionShapeError) -> bool
fn eq(&self, other: &ExtensionShapeError) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ExtensionShapeError
impl StructuralPartialEq for ExtensionShapeError
Auto Trait Implementations§
impl Freeze for ExtensionShapeError
impl RefUnwindSafe for ExtensionShapeError
impl Send for ExtensionShapeError
impl Sync for ExtensionShapeError
impl Unpin for ExtensionShapeError
impl UnsafeUnpin for ExtensionShapeError
impl UnwindSafe for ExtensionShapeError
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