pub trait InMemoryResponseExt {
    // Required methods
    fn new(status: StatusCode, headers: HeaderMap, body: InMemoryBody) -> Self;
    fn text(self) -> Result<String>;
    fn json<U: DeserializeOwned>(self) -> Result<U>;
    fn bytes(self) -> Result<Bytes>;
    fn sanitize(&mut self);
    fn get_cookie(&self, name: &str) -> Option<&str>;
}

Required Methods§

source

fn new(status: StatusCode, headers: HeaderMap, body: InMemoryBody) -> Self

source

fn text(self) -> Result<String>

source

fn json<U: DeserializeOwned>(self) -> Result<U>

source

fn bytes(self) -> Result<Bytes>

source

fn sanitize(&mut self)

Attempt to clear sensitive information from the response.

Object Safety§

This trait is not object safe.

Implementors§