pub struct HttpServer<F> { /* private fields */ }
Expand description
The HTTP server.
This struct is the main entry point for creating and running an HTTP server.
Start creating a new server by calling HttpServer::builder
.
Implementations§
Source§impl<F> HttpServer<F>
impl<F> HttpServer<F>
Sourcepub fn builder() -> HttpServerBuilder<F>
pub fn builder() -> HttpServerBuilder<F>
Create an instance of HttpServer
using the builder syntax
Source§impl<F> HttpServer<F>where
F: HttpServiceFactory + Clone + Send + 'static,
F::Error: Error + Send,
F::Service: Clone + Send + 'static,
<F::Service as HttpService>::Error: Error + Send + Sync,
<F::Service as HttpService>::ResBody: Send,
<<F::Service as HttpService>::ResBody as Body>::Data: Send,
<<F::Service as HttpService>::ResBody as Body>::Error: Error + Send + Sync,
impl<F> HttpServer<F>where
F: HttpServiceFactory + Clone + Send + 'static,
F::Error: Error + Send,
F::Service: Clone + Send + 'static,
<F::Service as HttpService>::Error: Error + Send + Sync,
<F::Service as HttpService>::ResBody: Send,
<<F::Service as HttpService>::ResBody as Body>::Data: Send,
<<F::Service as HttpService>::ResBody as Body>::Error: Error + Send + Sync,
Trait Implementations§
Source§impl<F: Clone> Clone for HttpServer<F>
impl<F: Clone> Clone for HttpServer<F>
Source§fn clone(&self) -> HttpServer<F>
fn clone(&self) -> HttpServer<F>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<F> Freeze for HttpServer<F>where
F: Freeze,
impl<F> !RefUnwindSafe for HttpServer<F>
impl<F> Send for HttpServer<F>where
F: Send,
impl<F> Sync for HttpServer<F>where
F: Sync,
impl<F> Unpin for HttpServer<F>where
F: Unpin,
impl<F> !UnwindSafe for HttpServer<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