socket_options.RdThese helpers read or set frequently used socket options. With the value
argument omitted, the current option value is returned; otherwise the
option is updated and the socket handle is returned invisibly. The
socket_linger() helper uses on and seconds to configure SO_LINGER.
socket_reuse_address(socket, value)
socket_keep_alive(socket, value)
socket_broadcast(socket, value)
socket_no_delay(socket, value)
socket_quick_ack(socket, value)
socket_receive_buffer_size(socket, value)
socket_send_buffer_size(socket, value)
socket_receive_timeout(socket, value)
socket_send_timeout(socket, value)
socket_linger(socket, on, seconds = 0L)The option value when reading; invisibly, the socket when setting.
s <- socket_create()
socket_reuse_address(s, TRUE)
socket_reuse_address(s)
#> [1] TRUE
socket_close(s)