Learn R Programming

svSocket (version 1.1.0)

close_socket_clients: Close one or more clients currently connected

Description

The socket servers asks to clients to nicely disconnect (possibly doing further process on their side). This function is used by stop_socket_server(), but it can also be invoked manually to ask for disconnection of a particular client. Note that, in this case, the client still can decide not to disconnect! The code send to ask for client disconnection is: \\f.

Usage

close_socket_clients(sockets = "all", server_port = 8888)

closeSocketClients(sockets = "all", server_port = 8888)

Arguments

sockets

the list of socket client names (sockXXX) to close, or "all" (by default) to disconnect all currently connected clients.

server_port

the corresponding R socket server port.

See Also

send_socket_clients()