Trait axum_tonic::NestTonic
source · pub trait NestTonic: Sized {
// Required method
fn nest_tonic<S>(self, svc: S) -> Self
where S: Service<Request<Body>, Error = Infallible, Response = Response<BoxBody>> + Clone + Send + 'static + NamedService,
S::Future: Send + 'static + Unpin;
}
Expand description
This trait automatically nests the NamedService at the correct path.
Required Methods§
sourcefn nest_tonic<S>(self, svc: S) -> Selfwhere
S: Service<Request<Body>, Error = Infallible, Response = Response<BoxBody>> + Clone + Send + 'static + NamedService,
S::Future: Send + 'static + Unpin,
fn nest_tonic<S>(self, svc: S) -> Selfwhere
S: Service<Request<Body>, Error = Infallible, Response = Response<BoxBody>> + Clone + Send + 'static + NamedService,
S::Future: Send + 'static + Unpin,
Nest a tonic-service at the root path of this router.
Object Safety§
This trait is not object safe.