[][src]Struct hyperdrive::service::CatchUnwind

pub struct CatchUnwind<S, R, H> where
    S: Service<ResBody = Body, Error = BoxedError> + Sync,
    S::Future: Send + 'static,
    R: IntoFuture<Item = Response<Body>, Error = BoxedError>,
    R::Future: Send + 'static,
    H: Fn(Box<dyn Any + Send>) -> R + Send + Sync + 'static, 
{ /* fields omitted */ }

A Service adapter that catches unwinding panics.

Returned by ServiceExt::catch_unwind.

Trait Implementations

impl<S, R, H> Clone for CatchUnwind<S, R, H> where
    S: Service<ResBody = Body, Error = BoxedError> + Clone + Sync,
    S::Future: Send + 'static,
    R: IntoFuture<Item = Response<Body>, Error = BoxedError>,
    R::Future: Send + 'static,
    H: Fn(Box<dyn Any + Send>) -> R + Send + Sync + 'static, 
[src]

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

Performs copy-assignment from source. Read more

impl<S: Debug, R: Debug, H: Debug> Debug for CatchUnwind<S, R, H> where
    S: Service<ResBody = Body, Error = BoxedError> + Sync,
    S::Future: Send + 'static,
    R: IntoFuture<Item = Response<Body>, Error = BoxedError>,
    R::Future: Send + 'static,
    H: Fn(Box<dyn Any + Send>) -> R + Send + Sync + 'static, 
[src]

impl<S, R, H> Service for CatchUnwind<S, R, H> where
    S: Service<ResBody = Body, Error = BoxedError> + Sync,
    S::Future: Send + 'static,
    R: IntoFuture<Item = Response<Body>, Error = BoxedError>,
    R::Future: Send + 'static,
    H: Fn(Box<dyn Any + Send>) -> R + Send + Sync + 'static, 
[src]

type ReqBody = S::ReqBody

The Payload body of the http::Request.

type ResBody = Body

The Payload body of the http::Response.

type Error = BoxedError

The error type that can occur within this Service. Read more

type Future = DefaultFuture<Response<Body>, BoxedError>

The Future returned by this Service.

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

Returns Ready when the service is able to process requests. Read more

Auto Trait Implementations

impl<S, R, H> Unpin for CatchUnwind<S, R, H> where
    S: Unpin

impl<S, R, H> Sync for CatchUnwind<S, R, H>

impl<S, R, H> Send for CatchUnwind<S, R, H> where
    S: Send

impl<S, R, H> UnwindSafe for CatchUnwind<S, R, H> where
    H: RefUnwindSafe,
    S: UnwindSafe

impl<S, R, H> RefUnwindSafe for CatchUnwind<S, R, H> where
    H: RefUnwindSafe,
    S: RefUnwindSafe

Blanket Implementations

impl<T> ServiceExt for T where
    T: Service
[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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<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