pub struct BoundServer { /* private fields */ }Expand description
Successfully bound HTTP service awaiting a shutdown signal.
Implementations§
Source§impl BoundServer
impl BoundServer
Sourcepub fn local_addr(&self) -> SocketAddr
pub fn local_addr(&self) -> SocketAddr
Returns the actual local address, including an assigned ephemeral port.
Sourcepub async fn run_with_shutdown<F>(self, shutdown: F) -> Result<(), ServerError>
pub async fn run_with_shutdown<F>(self, shutdown: F) -> Result<(), ServerError>
Serves until the supplied graceful-shutdown future resolves.
§Errors
Returns an HTTP listener/service I/O failure.
Auto Trait Implementations§
impl !Freeze for BoundServer
impl !RefUnwindSafe for BoundServer
impl !UnwindSafe for BoundServer
impl Send for BoundServer
impl Sync for BoundServer
impl Unpin for BoundServer
impl UnsafeUnpin for BoundServer
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