Trait asio::SocketListener [] [src]

pub trait SocketListener: Socket + Cancel {
    type Socket: Socket;
    fn accept<T: IoObject>(&self, io: &T) -> Result<(Self::Socket, Self::Endpoint)>;
    fn async_accept<A, F, T>(a: A, callback: F, obj: &Strand<T>) where A: Fn(&T) -> &Self + Send, F: FnOnce(Strand<T>, Result<(Self::Socket, Self::Endpoint)>) + Send;

    fn listen(&self) -> Result<()> { ... }
}

Associated Types

type Socket: Socket

Required Methods

fn accept<T: IoObject>(&self, io: &T) -> Result<(Self::Socket, Self::Endpoint)>

fn async_accept<A, F, T>(a: A, callback: F, obj: &Strand<T>) where A: Fn(&T) -> &Self + Send, F: FnOnce(Strand<T>, Result<(Self::Socket, Self::Endpoint)>) + Send

Provided Methods

fn listen(&self) -> Result<()>

Implementors