socket.listen( int ) => 0
Instance Public methods
Listens for connections, using the specified int as the
backlog. A call to listen only applies if the socket
is of type SOCK_STREAM or SOCK_SEQPACKET.
Parameter
backlog - the maximum length of the queue for pending
connections.
Example 1
require 'socket'
include Socket::Constants
socket = Socket.new( AF_INET, SOCK_STREAM, 0 )
sockaddr = Socket.pack_sockaddr_in( 2200, 'localhost' )
socket.bind( sockaddr )
socket.listen( 5 )
E