pub trait IntoErrorContext {
// Required method
fn into_error_context(self) -> ErrorContext;
}Expand description
Converts a type into an ErrorContext for error annotation.
This trait is used throughout the error handling pipeline to accept flexible context types when building composable errors.
Required Methods§
Sourcefn into_error_context(self) -> ErrorContext
fn into_error_context(self) -> ErrorContext
Converts self into an ErrorContext.
Implementations on Foreign Types§
Source§impl IntoErrorContext for &str
impl IntoErrorContext for &str
Source§fn into_error_context(self) -> ErrorContext
fn into_error_context(self) -> ErrorContext
Converts a string slice into a message context.
Source§impl IntoErrorContext for String
impl IntoErrorContext for String
Source§fn into_error_context(self) -> ErrorContext
fn into_error_context(self) -> ErrorContext
Converts an owned String into a message context.