libexpress 0.0.1
Express Server Framework in C
|
This contains the entry point to the library. More...
#include "router.h"
Go to the source code of this file.
Macros | |
#define | MAX_CON 100 |
Maximum simultaneous connections accepted by server instance. | |
Functions | |
server_t * | server_new (void) |
Creates a new server instance. More... | |
void | server_listen (server_t *server, port_t port) |
Makes the server instance listen for HTTP requests at specified port. More... | |
This contains the entry point to the library.
It contains and imports all the functions that are made public to the user.
Makes the server instance listen for HTTP requests at specified port.
The server instance listens for HTTP requests at the specified port and accepts requests from a maximum of MAX_CON
clients.
Since server_t
and router_t
are the same types, any router can be made to listen for connections, not just the server-instance. However, all routes requested will be resolved according to the router listening to the connection.
server | The server instance |
port | The port on which the server instance will listen for requests |
server_t * server_new | ( | void | ) |
Creates a new server instance.