pub trait BytesBody: Send {
// Required method
fn into_bytes<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Box<dyn StdError + Send + Sync + 'static>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}
Expand description
Object safe body trait
Required Methods§
Sourcefn into_bytes<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Box<dyn StdError + Send + Sync + 'static>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn into_bytes<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Box<dyn StdError + Send + Sync + 'static>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Convert the body into Bytes
This consumes the body. The behavior for calling this method multiple times is undefined.