[][src]Trait rocket::http::hyper::net::NetworkListener

pub trait NetworkListener: Clone {
    type Stream: NetworkStream + Send + Clone;
    fn accept(&mut self) -> Result<Self::Stream, Error>;
fn local_addr(&mut self) -> Result<SocketAddr, Error>; fn incoming(&mut self) -> NetworkConnections<Self> { ... }
fn set_read_timeout(&mut self, Option<Duration>) { ... }
fn set_write_timeout(&mut self, Option<Duration>) { ... } }

An abstraction to listen for connections on a certain port.

Associated Types

The stream produced for each connection.

Required Methods

Returns an iterator of streams.

Get the address this Listener ended up listening on.

Provided Methods

Important traits for NetworkConnections<'a, N>

Returns an iterator over incoming connections.

Sets the read timeout for all streams that are accepted

Sets the write timeout for all streams that are accepted

Implementors

impl NetworkListener for HttpListener
[src]

Important traits for NetworkConnections<'a, N>

impl<S> NetworkListener for HttpsListener<S> where
    S: SslServer<HttpStream> + Clone
[src]

Important traits for NetworkConnections<'a, N>