Qore HttpServerUtil Module Reference  0.3.12.1
HttpServer::HttpListenerInterface Class Referenceabstract

this abstract class defines the public interface of the private HttpListener class defined in the HttpServer module More...

Inheritance diagram for HttpServer::HttpListenerInterface:

Public Member Methods

abstract addUserThreadContext (hash uctx)
 adds user-defined data to be returned in the "uctx" context key when serving requests from this listener More...
 
 logResponse (hash< auto > cx, hash< auto > rv)
 method to log a response message More...
 
abstract auto removeUserThreadContext (*string k)
 removes the given key from the "uctx" context key; if no argument is provided, then the "uctx" context hash is removed entirely More...
 
- Public Member Methods inherited from HttpServer::AbstractLogger
abstract log (string fmt)
 called to log information to the registered log code More...
 
 logArgs (*softlist args)
 calls log() with the given args More...
 
abstract logError (string fmt)
 called to log error information to the registered error log code More...
 
 logErrorArgs (*softlist args)
 calls logError() with the given args More...
 

Detailed Description

this abstract class defines the public interface of the private HttpListener class defined in the HttpServer module

Member Function Documentation

◆ addUserThreadContext()

abstract HttpServer::HttpListenerInterface::addUserThreadContext ( hash  uctx)
pure virtual

adds user-defined data to be returned in the "uctx" context key when serving requests from this listener

Parameters
uctxuser-defined data to be returned in the "uctx" context key when serving requests from this listener

◆ logResponse()

HttpServer::HttpListenerInterface::logResponse ( hash< auto >  cx,
hash< auto >  rv 
)

method to log a response message

Parameters
cxthe call context
theresponse hash

◆ removeUserThreadContext()

abstract auto HttpServer::HttpListenerInterface::removeUserThreadContext ( *string  k)
pure virtual

removes the given key from the "uctx" context key; if no argument is provided, then the "uctx" context hash is removed entirely

Parameters
kthe key to remove from the "uctx" context hash; if no argument is provided, then the "uctx" context hash is removed entirely