Trait GenericResponse
Source pub trait GenericResponse: Send + Sync {
// Required methods
fn status(&self) -> StatusCode;
fn headers(&mut self) -> &BTreeMap<String, String>;
fn text<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<String, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn bytes<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Bytes, Error>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn bytes_stream(
&mut self,
) -> Pin<Box<dyn Stream<Item = Result<Bytes, Error>> + Send>>;
}