ascii-chat
Binary v0.16.114-28-gf5913657f
Library lib/v0.3.2-3302-gf5913657f
Video chat in your terminal
Loading...
Searching...
No Matches
tcp_server Struct Reference

The useful part of tcp server is in event_loop, listen_socket, listen_socket6, running: together they describe what is pending, who owns it, and how much data is valid. Keep the object with its parent operation and use the parent cleanup path. More...

#include <include/ascii-chat/network/tcp/server.h>

Data Fields

platform_event_loop_t * event_loop
 Owned while the asynchronous server runs.
socket_t listen_socket
 IPv4 listen socket.
socket_t listen_socket6
 IPv6 listen socket.
atomic_t running
 Server running flag (set false to shutdown).
tcp_server_config_t config
 Server configuration.

Detailed Description

The useful part of tcp server is in event_loop, listen_socket, listen_socket6, running: together they describe what is pending, who owns it, and how much data is valid. Keep the object with its parent operation and use the parent cleanup path.

Definition at line 42 of file include/ascii-chat/network/tcp/server.h.

Field Documentation

◆ config

tcp_server_config_t tcp_server::config

Server configuration.

Definition at line 47 of file include/ascii-chat/network/tcp/server.h.

Referenced by tcp_server_init(), and tcp_server_run().

◆ event_loop

platform_event_loop_t* tcp_server::event_loop

Owned while the asynchronous server runs.

Definition at line 43 of file include/ascii-chat/network/tcp/server.h.

◆ listen_socket

socket_t tcp_server::listen_socket

IPv4 listen socket.

Definition at line 44 of file include/ascii-chat/network/tcp/server.h.

Referenced by tcp_server_destroy(), and tcp_server_init().

◆ listen_socket6

socket_t tcp_server::listen_socket6

IPv6 listen socket.

Definition at line 45 of file include/ascii-chat/network/tcp/server.h.

Referenced by tcp_server_destroy(), and tcp_server_init().

◆ running

atomic_t tcp_server::running

Server running flag (set false to shutdown).

Definition at line 46 of file include/ascii-chat/network/tcp/server.h.

Referenced by tcp_server_destroy(), and tcp_server_init().


The documentation for this struct was generated from the following file: