pub struct Error<Data: Debug = ()> { /* private fields */ }
Expand description
An UEFI-related error with optionally additional payload data. The error
kind is encoded in the status
field (see Status
). Additional payload
may be inside the data
field.
Implementations§
Source§impl<Data: Debug> Error<Data>
impl<Data: Debug> Error<Data>
Sourcepub const fn to_err_without_payload(&self) -> Error<()>
pub const fn to_err_without_payload(&self) -> Error<()>
Transforms the generic payload of an error to ()
. This is useful if
you want
- to retain the erroneous status code,
- do not care about the payload, and
- refrain from generic type complexity in a higher API level.
Trait Implementations§
Source§impl<Data: Debug> Error for Error<Data>
impl<Data: Debug> Error for Error<Data>
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()
impl<Data: Eq + Debug> Eq for Error<Data>
impl<Data: Debug> StructuralPartialEq for Error<Data>
Auto Trait Implementations§
impl<Data> Freeze for Error<Data>where
Data: Freeze,
impl<Data> RefUnwindSafe for Error<Data>where
Data: RefUnwindSafe,
impl<Data> Send for Error<Data>where
Data: Send,
impl<Data> Sync for Error<Data>where
Data: Sync,
impl<Data> Unpin for Error<Data>where
Data: Unpin,
impl<Data> UnwindSafe for Error<Data>where
Data: 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