ascii-chat
Binary v0.15.83-53-gb711d8720
Library lib/v0.3.2-701-gb711d8720
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 34 of file include/ascii-chat/network/tcp/server.h.

Field Documentation

◆ config

tcp_server_config_t tcp_server::config

Server configuration.

Definition at line 39 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 35 of file include/ascii-chat/network/tcp/server.h.

◆ listen_socket

socket_t tcp_server::listen_socket

IPv4 listen socket.

Definition at line 36 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 37 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 38 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: