pub trait RragResultExt<T> {
// Required methods
fn with_rrag_context(self, context: &str) -> RragResult<T>;
fn map_to_rrag_error<F>(self, f: F) -> RragResult<T>
where F: FnOnce() -> RragError;
}Expand description
Extension trait for adding RRAG context to any Result
Required Methods§
Sourcefn with_rrag_context(self, context: &str) -> RragResult<T>
fn with_rrag_context(self, context: &str) -> RragResult<T>
Add context to an error
Sourcefn map_to_rrag_error<F>(self, f: F) -> RragResult<T>
fn map_to_rrag_error<F>(self, f: F) -> RragResult<T>
Map to a specific RRAG error type
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.