10 #ifndef K_API_HTTP_SERVER_H
11 #define K_API_HTTP_SERVER_H
136 #include <kApi/Io/kHttpServer.x.h>
Represents a 32-bit unsigned integer.
kStatus(kCall * kCallbackFx)(kPointer receiver, kPointer sender, void *args)
Callback signature for a generic event handler.
Definition: kApiDef.h:1030
Represents a void pointer.
Represents an unsigned integer that can store a pointer address.
Abstract base class for memory allocator types.
kStatus kHttpServer_LocalEndPoint(kHttpServer server, kIpEndPoint *endPoint)
Reports the local end-point for a running server.
Represents an IP address.
Definition: kNetwork.h:36
kStatus kHttpServer_Start(kHttpServer server)
Starts the server.
kStatus kHttpServer_Construct(kHttpServer *server, kAlloc allocator)
Constructs a kHttpServer object.
Implements a simple HTTP server.
kStatus kHttpServer_SetHandler(kHttpServer server, kCallbackFx function, kPointer receiver)
Sets the callback that will be invoked to process remote requests.
IP networking definitions.
Represents an enumeration of error codes.
Represents an IP end point (address, port).
Definition: kNetwork.h:171
kStatus kHttpServer_SetAddress(kHttpServer server, kIpAddress address)
Sets the local address to which the server should bind.
kStatus kHttpServer_Stop(kHttpServer server)
Stops the server.
kStatus kHttpServer_SetPort(kHttpServer server, k32u port)
Sets the local port to which the server should bind.
kStatus kHttpServer_SetMaxConnections(kHttpServer server, kSize capacity)
Sets the maximum number of simultaneous connections supported by the server.