class LOCAL_SOCKET_SERVER
Summary
Direct parents
Inherit list: SOCKET_SERVER
Overview
Creation features
{ACCESS}
Features
{}
{SOCKET_INPUT_OUTPUT_STREAM}
{}
{}
{ANY}
{EVENTS_SET, SOCKET}
  • fd: INTEGER_32
    The file descriptor of the socket; it is used to wait for some connection.
{SOCKET_INPUT_OUTPUT_STREAM}
{ANY}
{}
{}
Plugin
{}
Name resolution -- see LOCALHOST
{}
Macros for setting options
{}
access: LOCAL_ACCESS
writable attribute
{}
bind (a_sync: BOOLEAN): SOCKET
effective function
Create a socket for the stream to connect upon (used by the stream at creation)
ensure
  • has_socket(Result)
has_socket (socket: SOCKET): BOOLEAN
effective function
socket_disconnected (socket: SOCKET)
effective procedure
require
  • not socket.is_connected
  • has_socket(socket)
ensure
  • not has_socket(socket)
connected_sockets: FAST_ARRAY[LOCAL_SOCKET]
writable attribute
{}
The currently connected sockets
once function
{}
Common array containing all the currently disconnected sockets.
bind_socket (a_sync: BOOLEAN): LOCAL_SOCKET
effective function
{}
ensure
unbind_socket (socket: LOCAL_SOCKET)
effective procedure
{}
require ensure
kill_connections
effective procedure
{}
make (a_access: LOCAL_ACCESS, a_socket_fd: INTEGER_32)
effective procedure
{}
Connect to an access, which must also provide the file descriptor
require
  • a_access /= Void
  • valid_file_descriptor: a_socket_fd >= 0
can_connect: BOOLEAN
writable attribute
{ANY}
True if some client can connect to the server.
error: STRING
writable attribute
{ANY}
shutdown
effective procedure
{ANY}
Wait for the connections to finish, then stop the server.
No more connections will be accepted.
require ensure
halt
effective procedure
{ANY}
Force all the connected sockets to disconnect, then shutdown
require ensure
new_stream (read_sync: BOOLEAN): SOCKET_INPUT_OUTPUT_STREAM
effective function
{ANY}
writable attribute
The file descriptor of the socket; it is used to wait for some connection.
unbind (socket: SOCKET)
effective procedure
Close the socket and unbind it
require ensure
event_connection: EVENT_DESCRIPTOR
effective function
{ANY}
connection_occurred: NETWORK_CONNECTION_OCCURRED
writable attribute
{}
last_error: STRING
effective function
{}
last_error_number: INTEGER_32
effective function
{}
require
net_tcp (ip_a: INTEGER_32, ip_b: INTEGER_32, ip_c: INTEGER_32, ip_d: INTEGER_32, a_port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_udp (ip_a: INTEGER_32, ip_b: INTEGER_32, ip_c: INTEGER_32, ip_d: INTEGER_32, a_port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_local (a_port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_select (a_fd: INTEGER_32, a_timeout: REAL_64): INTEGER_32
{}
net_read (a_fd: INTEGER_32, a_count: INTEGER_32, a_buffer: POINTER, sync: BOOLEAN): INTEGER_32
{}
net_write (a_fd: INTEGER_32, a_count: INTEGER_32, a_buffer: NATIVE_ARRAY[CHARACTER]): INTEGER_32
{}
net_accept (a_fd: INTEGER_32, a_val: NATIVE_ARRAY[INTEGER_32], a_sync: BOOLEAN)
{}
net_disconnect (a_fd: INTEGER_32)
{}
net_shutdown (a_fd: INTEGER_32)
{}
net_last_error: POINTER
{}
net_last_error_number: INTEGER_32
{}
net_last_error_try_again: BOOLEAN
{}
net_hostname (a_hostname: POINTER): INTEGER_32
{}
net_tcp_server (port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_udp_server (port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_local_server (port: INTEGER_32, a_sync: BOOLEAN): INTEGER_32
{}
net_bind_server (socket: INTEGER_32, port: INTEGER_32, sockfamily: INTEGER_32): INTEGER_32
{}
net_set_int_option (fd: INTEGER_32, level: INTEGER_32, optname: INTEGER_32, opt_val: INTEGER_32): INTEGER_32
{}
net_tcp_socket (sync: BOOLEAN): INTEGER_32
{}
net_udp_socket (sync: BOOLEAN): INTEGER_32
{}
net_local_socket (sync: BOOLEAN): INTEGER_32
{}
net_gethostname: POINTER
{}
net_sethostname (hn: POINTER, size: INTEGER_32)
{}
net_getdomainname: POINTER
{}
net_setdomainname (dn: POINTER, size: INTEGER_32)
{}
sol_socket: INTEGER_32
{}
so_reuse_addr: INTEGER_32
{}
af_inet: INTEGER_32
{}