Context

Trait Context 

Source
pub trait Context<T, E> {
    // Required methods
    fn add_context<C>(self, ctx: C) -> AsyncFusexResult<T>
       where C: Into<String>;
    fn with_context<C, F>(self, f: F) -> AsyncFusexResult<T>
       where C: Into<String>,
             F: FnOnce() -> C;
}

Required Methods§

Source

fn add_context<C>(self, ctx: C) -> AsyncFusexResult<T>
where C: Into<String>,

Source

fn with_context<C, F>(self, f: F) -> AsyncFusexResult<T>
where C: Into<String>, F: FnOnce() -> C,

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.

Implementations on Foreign Types§

Source§

impl<T, E> Context<T, E> for Result<T, E>

Source§

fn add_context<C>(self, ctx: C) -> AsyncFusexResult<T>
where C: Into<String>,

Source§

fn with_context<C, F>(self, context_func: F) -> AsyncFusexResult<T>
where C: Into<String>, F: FnOnce() -> C,

Implementors§