Struct tarpc::server::InFlightRequest[][src]

pub struct InFlightRequest<Req, Res> { /* fields omitted */ }

A request produced by Channel::requests.

Implementations

impl<Req, Res> InFlightRequest<Req, Res>[src]

pub fn get(&self) -> &Request<Req>[src]

Returns a reference to the request.

pub async fn execute<S>(self, serve: S) where
    S: Serve<Req, Resp = Res>, 
[src]

Returns a future that executes the request using the given service function. The service function’s output is automatically sent back to the Channel that yielded this request. The request will be executed in the scope of this request’s context.

The returned future will stop executing when the first of the following conditions is met:

  1. The channel that yielded this request receives a cancellation message for this request.
  2. The request deadline is reached.
  3. The service function completes.

Trait Implementations

impl<Req: Debug, Res: Debug> Debug for InFlightRequest<Req, Res>[src]

Auto Trait Implementations

impl<Req, Res> !RefUnwindSafe for InFlightRequest<Req, Res>

impl<Req, Res> Send for InFlightRequest<Req, Res> where
    Req: Send,
    Res: Send

impl<Req, Res> Sync for InFlightRequest<Req, Res> where
    Req: Sync,
    Res: Send

impl<Req, Res> Unpin for InFlightRequest<Req, Res> where
    Req: Unpin

impl<Req, Res> !UnwindSafe for InFlightRequest<Req, Res>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> FutureExt for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,