pub struct MapResponse<C, F> { /* private fields */ }
Expand description
A Client that applies a function to the returned response.
Trait Implementations§
Source§impl<'a, C, F, Req, Resp, Resp2> Client<'a, Req> for MapResponse<C, F>
impl<'a, C, F, Req, Resp, Resp2> Client<'a, Req> for MapResponse<C, F>
Source§fn call(&'a mut self, ctx: Context, request: Req) -> Self::Future
fn call(&'a mut self, ctx: Context, request: Req) -> Self::Future
Initiates a request, sending it to the dispatch task. Read more
Source§fn map_response<F, R>(self, f: F) -> MapResponse<Self, F>
fn map_response<F, R>(self, f: F) -> MapResponse<Self, F>
Returns a Client that applies a post-processing function to the returned response.
Source§fn with_request<F, Req2>(self, f: F) -> WithRequest<Self, F>
fn with_request<F, Req2>(self, f: F) -> WithRequest<Self, F>
Returns a Client that applies a pre-processing function to the request.
Source§impl<C: Clone, F: Clone> Clone for MapResponse<C, F>
impl<C: Clone, F: Clone> Clone for MapResponse<C, F>
Source§fn clone(&self) -> MapResponse<C, F>
fn clone(&self) -> MapResponse<C, F>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<C, F> Freeze for MapResponse<C, F>
impl<C, F> RefUnwindSafe for MapResponse<C, F>where
C: RefUnwindSafe,
F: RefUnwindSafe,
impl<C, F> Send for MapResponse<C, F>
impl<C, F> Sync for MapResponse<C, F>
impl<C, F> Unpin for MapResponse<C, F>
impl<C, F> UnwindSafe for MapResponse<C, F>where
C: UnwindSafe,
F: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more