Trait ServiceExt

Source
pub trait ServiceExt<I>: Service<I> {
    // Provided methods
    fn flow<U>(self, service: U) -> impl Service<I, Out = U::Out>
       where Self: Sized,
             U: Service<Self::Out> { ... }
    fn spawn(self, buffer: usize) -> Spawn<Self>
       where Self: Sized { ... }
    fn map<U, F>(self, map: F) -> impl Service<I, Out = U>
       where Self: Sized,
             F: Send + FnMut(Self::Out) -> U { ... }
    fn abort_token(
        self,
        token: impl Future + Send,
    ) -> impl Service<I, Out = Self::Out>
       where Self: Sized { ... }
}

Provided Methods§

Source

fn flow<U>(self, service: U) -> impl Service<I, Out = U::Out>
where Self: Sized, U: Service<Self::Out>,

Source

fn spawn(self, buffer: usize) -> Spawn<Self>
where Self: Sized,

Source

fn map<U, F>(self, map: F) -> impl Service<I, Out = U>
where Self: Sized, F: Send + FnMut(Self::Out) -> U,

Source

fn abort_token( self, token: impl Future + Send, ) -> impl Service<I, Out = Self::Out>
where Self: Sized,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<I, T: Service<I>> ServiceExt<I> for T