Module: hcjeTools/server/requestListener

Listener for use with the HCJE server. This module does not need to be used directly. It is used soley by the server.js script.

Source:

Methods

(static) createRequestListener(root) → {module:hcjeTools/server/requestListener~RequestListener}

Create a listener function for use with the http server.

Parameters:
Name Type Description
root string

Path from where files are served

Source:
See:
Throws:

Thrown if root not defined.

Type
Error
Returns:
Type
module:hcjeTools/server/requestListener~RequestListener

Type Definitions

RequestListener(request, response)

Function added to the request when a server is created.

Parameters:
Name Type Description
request ClientRequest

The ClientRequest

response ServerResponse

The ServerResponse

Source: