Trait BodyExt

Source
pub trait BodyExt: Body {
    // Provided methods
    fn next(&mut self) -> Next<'_, Self> 
       where Self: Unpin { ... }
    fn map_err<F, E>(self, f: F) -> MapErr<Self, F>
       where Self: Sized,
             F: FnMut(Self::Error) -> E { ... }
    fn stream(self) -> BodyStream<Self>
       where Self: Sized { ... }
    fn boxed(self) -> BoxBody
       where Self: Sized + 'static,
             Self::Error: Into<Box<dyn Error>> { ... }
}

Provided Methods§

Source

fn next(&mut self) -> Next<'_, Self>
where Self: Unpin,

Source

fn map_err<F, E>(self, f: F) -> MapErr<Self, F>
where Self: Sized, F: FnMut(Self::Error) -> E,

Source

fn stream(self) -> BodyStream<Self>
where Self: Sized,

Source

fn boxed(self) -> BoxBody
where Self: Sized + 'static, Self::Error: Into<Box<dyn Error>>,

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.

Implementors§

Source§

impl<B> BodyExt for B
where B: Body,