pub trait Bufferer<Body: Body> {
    type Data: Buf;
    type Error;

    // Required method
    fn buffer<'life0, 'async_trait>(
        &'life0 self,
        body: Body
    ) -> Pin<Box<dyn Future<Output = Result<Self::Data, Self::Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

The ability to buffer an http_body::Body.

Required Associated Types§

source

type Data: Buf

The buffer type.

source

type Error

An error that can occur while buffering.

Required Methods§

source

fn buffer<'life0, 'async_trait>( &'life0 self, body: Body ) -> Pin<Box<dyn Future<Output = Result<Self::Data, Self::Error>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,

Buffer the given body into Self::Data.

Implementors§