pub struct SimpleHttpServer<A, F> { /* private fields */ }
Implementations§
Source§impl<A, F> SimpleHttpServer<A, F>
impl<A, F> SimpleHttpServer<A, F>
pub fn new(argument: A, callback: fn(A, RawConnection) -> F) -> Self
Source§impl<A, F> SimpleHttpServer<A, F>
impl<A, F> SimpleHttpServer<A, F>
pub fn max_request_header_count(&mut self, count: usize) -> &mut Self
pub fn min_buffer_size(&mut self, size: usize) -> &mut Self
pub fn max_buffer_size(&mut self, size: usize) -> &mut Self
Trait Implementations§
Source§impl<A, F> Server for SimpleHttpServer<A, F>
impl<A, F> Server for SimpleHttpServer<A, F>
type Transport = TcpStream
type SocketHandler = RawSocketHandler
type ConnectionHandler = ConnectionHandleCallback<A, TcpStream, F>
fn create_handlers(&mut self) -> (Self::SocketHandler, Self::ConnectionHandler)
fn before_listen(&mut self, listener: &mut TcpListener) -> Result<()>
fn start<S>(self, bind_addr: SocketAddr, spawner: S) -> ServerHandle
Auto Trait Implementations§
impl<A, F> Freeze for SimpleHttpServer<A, F>where
A: Freeze,
impl<A, F> RefUnwindSafe for SimpleHttpServer<A, F>where
A: RefUnwindSafe,
impl<A, F> Send for SimpleHttpServer<A, F>where
A: Send,
impl<A, F> Sync for SimpleHttpServer<A, F>where
A: Sync,
impl<A, F> Unpin for SimpleHttpServer<A, F>where
A: Unpin,
impl<A, F> UnwindSafe for SimpleHttpServer<A, F>where
A: UnwindSafe,
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