Trait axum_server::service::MakeServiceRef[][src]

pub trait MakeServiceRef<Target, Request>: Sealed<(Target, Request)> {
    type Service: Service<Request, Response = Response<Self::Body>, Error = Self::Error, Future = Self::Future> + Send + 'static;
    type Body: Body<Data = Self::BodyData, Error = Self::BodyError> + Send + 'static;
    type BodyData: Send + 'static;
    type BodyError: Into<Box<dyn Error + Send + Sync>>;
    type Error: Into<Box<dyn Error + Send + Sync>>;
    type Future: Future<Output = Result<Response<Self::Body>, Self::Error>> + Send + 'static;
    type MakeError: Into<Box<dyn Error + Send + Sync>>;
    type MakeFuture: Future<Output = Result<Self::Service, Self::MakeError>>;
    fn poll_ready(
        &mut self,
        cx: &mut Context<'_>
    ) -> Poll<Result<(), Self::MakeError>>;
fn make_service(&mut self, target: &Target) -> Self::MakeFuture; }
Expand description

Modified version of MakeService that takes a &Target and has required trait bounds for serve.

This trait is sealed and cannot be implemented for types outside this crate.

Associated Types

Required methods

Implementors