pub struct WithGracefulShutdown<L, M, S, F> { /* private fields */ }
Expand description
Serve future with graceful shutdown enabled.
Implementations§
Source§impl<L, M, S, F> WithGracefulShutdown<L, M, S, F>where
L: Listener,
impl<L, M, S, F> WithGracefulShutdown<L, M, S, F>where
L: Listener,
Sourcepub fn local_addr(&self) -> Result<L::Addr>
pub fn local_addr(&self) -> Result<L::Addr>
Returns the local address this server is bound to.
Trait Implementations§
Source§impl<L, M, S, F> Debug for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> Debug for WithGracefulShutdown<L, M, S, F>
Source§impl<L, M, S, F> IntoFuture for WithGracefulShutdown<L, M, S, F>where
L: Listener,
L::Addr: Debug,
M: for<'a> Service<IncomingStream<'a, L>, Error = Infallible, Response = S> + Send + 'static,
for<'a> <M as Service<IncomingStream<'a, L>>>::Future: Send,
S: Service<Request, Response = Response, Error = Infallible> + Clone + Send + 'static,
S::Future: Send,
F: Future<Output = ()> + Send + 'static,
impl<L, M, S, F> IntoFuture for WithGracefulShutdown<L, M, S, F>where
L: Listener,
L::Addr: Debug,
M: for<'a> Service<IncomingStream<'a, L>, Error = Infallible, Response = S> + Send + 'static,
for<'a> <M as Service<IncomingStream<'a, L>>>::Future: Send,
S: Service<Request, Response = Response, Error = Infallible> + Clone + Send + 'static,
S::Future: Send,
F: Future<Output = ()> + Send + 'static,
Source§type IntoFuture = ServeFuture
type IntoFuture = ServeFuture
Which kind of future are we turning this into?
Source§fn into_future(self) -> Self::IntoFuture
fn into_future(self) -> Self::IntoFuture
Creates a future from a value. Read more
Auto Trait Implementations§
impl<L, M, S, F> Freeze for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> RefUnwindSafe for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> Send for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> Sync for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> Unpin for WithGracefulShutdown<L, M, S, F>
impl<L, M, S, F> UnwindSafe for WithGracefulShutdown<L, M, S, F>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more