v2026.2.1
All Bundles

HttpsRequestHandler

Request handler for HTTPS GET and POST requests.

Sample configuration file<./p>

Inherits: Thread
use Web.HTTP.Server;

class Test {
   function : Main(args : String[]) ~ Nil {
      WebServer->ServeSecure("config/simple_config.json");
   }
}

class RequestHandler from HttpsRequestHandler {
   New() {
      Parent();
   }
   
   method : ProcessGet(request : Request, response : Response) ~ Bool {
      return response->HasStaticHandler();
   }

   method : ProcessPost(request : Request, response : Response) ~ Bool {
      return false;
   }
}

Operations

GetHeaders

Get HTTP headers

method : public : GetHeaders() ~ Map<String,String>

Return

TypeDescription
Map<String,String>HTTP headers

New

Constructor

New()

ProcessGet

Callback for GET requests

method : private : virtual : ProcessGet(request:Web.HTTP.Server.Request, response:Web.HTTP.Server.Response) ~ Bool

Parameters

NameTypeDescription
requestRequestHTTP request
responseResponseHTTP response

Return

TypeDescription
Booltrue to continue processing, false otherwise

ProcessPost

Callback for POST requests

method : private : virtual : ProcessPost(request:Web.HTTP.Server.Request, response:Web.HTTP.Server.Response) ~ Bool

Parameters

NameTypeDescription
requestRequestHTTP request
responseResponseHTTP response

Return

TypeDescription
Booltrue to continue processing, false otherwise

ProcessResponse

Processes the HTTPS response

method : private : ProcessResponse(response:Response, is_head:Bool) ~ Nil

Parameters

NameTypeDescription
responseResponseHTTP response
is_headBooltrue if HEAD request, false otherwise

Run

Executes the request handler thread

method : public : Run(param:Base) ~ Nil

Parameters

NameTypeDescription
paramBasethread parameter containing client socket

SetConfig

Sets the server configuration

method : public : SetConfig(server_config:WebServerConfig, is_debug:Bool) ~ Nil

Parameters

NameTypeDescription
server_configWebServerConfigweb server configuration
is_debugBooltrue for debug output, false otherwise