11#define _SNF_VER "0.0.1-alpha"
46#define SNF_Total_Data (SNF_Total_Data_Rcv + SNF_Total_Data_Snt)
55#define UNIT_SCEPARATOR "\x1F"
88#define snf_rcv(Client, Buffer, _Size) snf_rcv_(Client, Buffer, _Size, 0)
90#define snf_rcv_PEEK(Client, Buffer, _Size) snf_rcv_(Client, Buffer, _Size, MSG_PEEK)
This file includes necessary Checks and includes the the nesessary libraries of the library.
This file Defines everything related to handling Clients.
thpool * Ntwrk
The thread pool that controls the working of the Framework.
_Atomic uint64_t SNF_Total_Data_Snt
Saves the Total data sent so far.
struct sockaddr_in SNF_CLIENT_ADDR
Structure that saves the Client's sockaddr_in.
struct sockaddr_in SNF_SERVER_ADDR
Structure that saves the Server's sockaddr_in.
int snf_snd(SNF_CLT *Client, const char *Buffer, int _Size)
Sends a Buffer to Client's SNF_CLT::sock.
_Atomic uint64_t SNF_Total_Data_Rcv
Saves the Total data received so far.
int SNF_MAX_QUEUE
Max Queue allowed to wait to be accepted at once.
socklen_t SNF_CLIENT_LEN
Used for accept's length argument.
int SNF_SERVER_SOCKET
the main Socket that accepts new incoming connections
int snf_rcv_(SNF_CLT *Client, void *Buffer, int _Size, int _Flags)
Receives a Buffer from Client's SNF_CLT::sock.
void snf_network_init()
Initializes the Network Framwork.
int SNF_PORT
Defines the Framework's TCP/IP's port.
void snf_network_join()
See snf_thpool_join (Works on the Ntwrk Thread Pool)
The structure for each saved client.
Definition clt.h:25
The structure for a Thread Pool.
Definition thpool.h:47
this file Defines everything related to ThreadPool