pub struct Socket<T> { /* private fields */ }
Implementations§
Source§impl Socket<Socket<'static>>
impl Socket<Socket<'static>>
pub async fn connect<T, U>(
&mut self,
remote_endpoint: T,
local_endpoint: U,
) -> Result<(), TcpSocketError>where
T: Into<IpEndpoint>,
U: Into<IpListenEndpoint>,
pub async fn accept_with_keep_alive( &mut self, local_endpoint: impl Into<IpListenEndpoint>, keep_alive_interval: Option<Duration>, ) -> Result<(), TcpSocketError>
pub async fn accept( &mut self, local_endpoint: impl Into<IpListenEndpoint>, ) -> Result<(), TcpSocketError>
pub fn close(&mut self)
pub fn abort(&mut self)
Trait Implementations§
Source§impl ErrorType for Socket<Socket<'static>>
impl ErrorType for Socket<Socket<'static>>
Source§type Error = TcpSocketError
type Error = TcpSocketError
Error type of all the IO operations on this type.