Module Async_extra.Tcp.Where_to_listen

A Where_to_listen describes the socket that a tcp server should listen on.

type ('address, 'listening_on) t constraint 'address = [< Async_extra__.Import.Socket.Address.t ]
include sig ... end
val sexp_of_t : ('address ‑> Base.Sexp.t) ‑> ('listening_on ‑> Base.Sexp.t) ‑> ('address'listening_ont ‑> Base.Sexp.t
type inet = (Async_extra__.Import.Socket.Address.Inet.t, int) t
include sig ... end
val sexp_of_inet : inet ‑> Base.Sexp.t
type unix = (Async_extra__.Import.Socket.Address.Unix.t, string) t
include sig ... end
val sexp_of_unix : unix ‑> Base.Sexp.t
val create : socket_type:'address Async_extra__.Import.Socket.Type.t ‑> address:'address ‑> listening_on:('address ‑> 'listening_on) ‑> ('address'listening_ont
val address : ('address_t ‑> 'address
val bind_to : Bind_to_address.t ‑> Bind_to_port.t ‑> inet

Listen on the specified port on the specified addresses.

val of_port : int ‑> inet

of_port port is bind_to All_addresses (On_port port).

val of_port_chosen_by_os : inet

of_port_chosen_by_os port is bind_to All_addresses On_port_chosen_by_os.

val of_file : string ‑> unix

Listen on a unix domain socket using the specified path.