[][src]Struct hyperdrive::service::MakeServiceByCloning

pub struct MakeServiceByCloning<S: Service + Clone> { /* fields omitted */ }

Implements Hyper's MakeService trait by cloning a service S for every incoming connection.

Both SyncService and AsyncService already implement MakeService using the same implementation (cloning themselves), so you don't need this if you are using either of those directly.

This type is returned by ServiceExt::make_service_by_cloning.

Trait Implementations

impl<S: Copy + Service + Clone> Copy for MakeServiceByCloning<S>[src]

impl<S: Clone + Service> Clone for MakeServiceByCloning<S>[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<S: Debug + Service + Clone> Debug for MakeServiceByCloning<S>[src]

impl<Ctx, S: Service + Clone> MakeService<Ctx> for MakeServiceByCloning<S>[src]

type ReqBody = S::ReqBody

The Payload body of the http::Request.

type ResBody = S::ResBody

The Payload body of the http::Response.

type Error = S::Error

The error type that can be returned by Services.

type Service = S

The resolved Service from new_service().

type Future = FutureResult<S, Self::MakeError>

The future returned from new_service of a Service.

type MakeError = BoxedError

The error type that can be returned when creating a new Service.

fn poll_ready(&mut self) -> Result<Async<()>, Self::MakeError>[src]

Returns Ready when the constructor is ready to create a new Service. Read more

Auto Trait Implementations

impl<S> Sync for MakeServiceByCloning<S> where
    S: Sync

impl<S> Unpin for MakeServiceByCloning<S> where
    S: Unpin

impl<S> Send for MakeServiceByCloning<S> where
    S: Send

impl<S> UnwindSafe for MakeServiceByCloning<S> where
    S: UnwindSafe

impl<S> RefUnwindSafe for MakeServiceByCloning<S> where
    S: RefUnwindSafe

Blanket Implementations

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From<T> for 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<T> Borrow<T> for T where
    T: ?Sized
[src]

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

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

impl<T> Erased for T

impl<N, Ctx> MakeService<Ctx> for N where
    N: NewService
[src]

type ReqBody = <N as NewService>::ReqBody

The Payload body of the http::Request.

type ResBody = <N as NewService>::ResBody

The Payload body of the http::Response.

type Error = <N as NewService>::Error

The error type that can be returned by Services.

type Service = <N as NewService>::Service

The resolved Service from new_service().

type Future = <N as NewService>::Future

The future returned from new_service of a Service.

type MakeError = <N as NewService>::InitError

The error type that can be returned when creating a new Service.