g_server = maxon::NetworkWebServerClass().Create() 
iferr_return;
 
 
  const bool useSSL = false;
 
  
 
  
  g_server.ObservableHandleRequest(
true).AddObserver(WebServerCallback) 
iferr_return;
 
const char const char * name
Definition: abstract.h:195
 
Definition: string.h:1287
 
#define DiagnosticOutput(formatString,...)
Definition: debugdiagnostics.h:170
 
maxon::NetworkIpAddrPort NetworkIpAddrPort
Definition: operatingsystem.h:312
 
static const WILDCARD_IPV4_ADDRESS_TYPE WILDCARD_IPV4_ADDRESS
Definition: network_ip_addr.h:45
 
static const Int WILDCARD_IP_PORT
Any IP port.
Definition: network_ip_addr.h:60
 
#define iferr_return
Definition: resultbase.h:1531
 
  The behaviour of the web-server is defined by implementing the ObservableHandleRequest. The callback function reacts to an incoming HTTP request and can return a message or an error.
 
static maxon::Result<void> WebServerCallback(
const maxon::NetworkWebServerRef& server, 
const maxon::NetworkHttpHandlerRef& remoteConnection, 
const maxon::DataDictionary& request)
 
{
 
  
  const maxon::Bool   keepAlive = connectionType.FindUpper(
"KEEP-ALIVE"_s, 
nullptr, 0);
 
 
  
  const maxon::Bool isGetOrPostRequest = isGetRequest || isPostRequest;
 
 
  if (isGetOrPostRequest && keepAlive)
  {
    
 
    
    
    if (fileLower == "marco"_s)
    {
      
 
      
 
      
 
    }
    
  }
}
Definition: string.h:1542
 
const char * message
Definition: pyerrors.h:189
 
Int64 Int
signed 32/64 bit int, size depends on the platform
Definition: apibase.h:187
 
bool Bool
boolean type, possible values are only false/true, 8 bit
Definition: apibase.h:180
 
return OK
Definition: apibase.h:2740
 
#define MAXON_SOURCE_LOCATION
Definition: memoryallocationbase.h:69
 
PyWideStringList Py_ssize_t length
Definition: initconfig.h:448
 
@ CALL_NEXT_HANDLER
the request was not processed by this message handler, continue with the next one.
 
@ NOTFOUND
return a http file not found error.
 
HTTPREQUESTTYPE
Definition: network_webserver.h:284
 
#define iferr_scope
Definition: resultbase.h:1396
 
const char const char const char * file
Definition: object.h:439