pub trait ErrorContextDisplay<T> {
// Required methods
fn kind_disp(self, kind: T) -> UniError<T>;
fn context_disp(self, context: impl Into<Cow<'static, str>>) -> UniError<T>
where T: Default;
fn kind_context_disp(
self,
kind: T,
context: impl Into<Cow<'static, str>>,
) -> UniError<T>;
fn wrap_disp(self) -> UniError<T>
where T: Default;
}Expand description
A trait for wrapping an existing error with a additional context (for Display types).
Required Methods§
Sourcefn kind_disp(self, kind: T) -> UniError<T>
fn kind_disp(self, kind: T) -> UniError<T>
Wraps the existing error with the provided kind (for Display types).
Sourcefn context_disp(self, context: impl Into<Cow<'static, str>>) -> UniError<T>where
T: Default,
fn context_disp(self, context: impl Into<Cow<'static, str>>) -> UniError<T>where
T: Default,
Wraps the existing error with the provided context (for Display types).
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.