[−][src]Trait hyper::net::NetworkListener
An abstraction to listen for connections on a certain port.
Associated Types
type Stream: NetworkStream + Send + Clone
The stream produced for each connection.
Required Methods
fn accept(&mut self) -> Result<Self::Stream>
Returns an iterator of streams.
fn local_addr(&mut self) -> Result<SocketAddr>
Get the address this Listener ended up listening on.
Provided Methods
ⓘImportant traits for NetworkConnections<'a, N>
fn incoming(&mut self) -> NetworkConnections<Self>
Returns an iterator over incoming connections.
fn set_read_timeout(&mut self, _: Option<Duration>)
Sets the read timeout for all streams that are accepted
fn set_write_timeout(&mut self, _: Option<Duration>)
Sets the write timeout for all streams that are accepted
Implementors
impl NetworkListener for HttpListener
[src]
impl NetworkListener for HttpListener
type Stream = HttpStream
fn accept(&mut self) -> Result<HttpStream>
[src]
fn accept(&mut self) -> Result<HttpStream>
fn local_addr(&mut self) -> Result<SocketAddr>
[src]
fn local_addr(&mut self) -> Result<SocketAddr>
fn set_read_timeout(&mut self, duration: Option<Duration>)
[src]
fn set_read_timeout(&mut self, duration: Option<Duration>)
fn set_write_timeout(&mut self, duration: Option<Duration>)
[src]
fn set_write_timeout(&mut self, duration: Option<Duration>)
ⓘImportant traits for NetworkConnections<'a, N>fn incoming(&mut self) -> NetworkConnections<Self>
[src]
ⓘImportant traits for NetworkConnections<'a, N>
fn incoming(&mut self) -> NetworkConnections<Self>
impl<S: SslServer + Clone> NetworkListener for HttpsListener<S>
[src]
impl<S: SslServer + Clone> NetworkListener for HttpsListener<S>
type Stream = S::Stream
fn accept(&mut self) -> Result<S::Stream>
[src]
fn accept(&mut self) -> Result<S::Stream>
fn local_addr(&mut self) -> Result<SocketAddr>
[src]
fn local_addr(&mut self) -> Result<SocketAddr>
fn set_read_timeout(&mut self, duration: Option<Duration>)
[src]
fn set_read_timeout(&mut self, duration: Option<Duration>)
fn set_write_timeout(&mut self, duration: Option<Duration>)
[src]
fn set_write_timeout(&mut self, duration: Option<Duration>)
ⓘImportant traits for NetworkConnections<'a, N>fn incoming(&mut self) -> NetworkConnections<Self>
[src]
ⓘImportant traits for NetworkConnections<'a, N>
fn incoming(&mut self) -> NetworkConnections<Self>