Skip to main content

IntoEndpointServiceWithState

Trait IntoEndpointServiceWithState 

pub trait IntoEndpointServiceWithState<T, State>: Sealed<T, State> {
    type Service: Service<Request, Output = Response, Error = Infallible>;

    // Required method
    fn into_endpoint_service_with_state(self, state: State) -> Self::Service;
}

Required Associated Types§

type Service: Service<Request, Output = Response, Error = Infallible>

Required Methods§

fn into_endpoint_service_with_state(self, state: State) -> Self::Service

convert the type into a rama_core::Service with state.

Implementors§

§

impl<F, T, State> IntoEndpointServiceWithState<(F, T), State> for F
where F: EndpointServiceFn<T, State>, T: Send + 'static, State: Send + Sync + Clone + 'static,

§

impl<R, State> IntoEndpointServiceWithState<(), State> for R
where R: IntoResponse + Clone + Send + Sync + 'static,

§

impl<S, R, State> IntoEndpointServiceWithState<(R,), State> for S
where S: Service<Request, Output = R, Error = Infallible>, R: IntoResponse + Send + Sync + 'static,