pub enum StructReason<T: DomainReason> {
Universal(UvsReason),
Domain(T),
}Expand description
Represents the root cause of an error, which can be either a domain-specific reason or a universal system reason.
Variants§
Trait Implementations§
Source§impl<T: Clone + DomainReason> Clone for StructReason<T>
impl<T: Clone + DomainReason> Clone for StructReason<T>
Source§fn clone(&self) -> StructReason<T>
fn clone(&self) -> StructReason<T>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<T: Debug + DomainReason> Debug for StructReason<T>
impl<T: Debug + DomainReason> Debug for StructReason<T>
Source§impl<T> Display for StructReason<T>where
T: Display + DomainReason,
impl<T> Display for StructReason<T>where
T: Display + DomainReason,
Source§impl<T: DomainReason> Error for StructReason<T>
impl<T: DomainReason> Error for StructReason<T>
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<T: DomainReason + ErrorCode> ErrorCode for StructReason<T>
impl<T: DomainReason + ErrorCode> ErrorCode for StructReason<T>
fn error_code(&self) -> i32
Source§impl<T: DomainReason> From<T> for StructReason<T>
impl<T: DomainReason> From<T> for StructReason<T>
Source§impl<T: DomainReason> From<UvsReason> for StructReason<T>
impl<T: DomainReason> From<UvsReason> for StructReason<T>
Source§impl<T: PartialEq + DomainReason> PartialEq for StructReason<T>
impl<T: PartialEq + DomainReason> PartialEq for StructReason<T>
impl<T: DomainReason> StructuralPartialEq for StructReason<T>
Auto Trait Implementations§
impl<T> Freeze for StructReason<T>where
T: Freeze,
impl<T> RefUnwindSafe for StructReason<T>where
T: RefUnwindSafe,
impl<T> Send for StructReason<T>where
T: Send,
impl<T> Sync for StructReason<T>where
T: Sync,
impl<T> Unpin for StructReason<T>where
T: Unpin,
impl<T> UnwindSafe for StructReason<T>where
T: UnwindSafe,
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