HTTPRequestHandling
public protocol HTTPRequestHandling: class
Class protocol containing a handle()
function that implements HTTPRequestHandler
to respond to incoming HTTP requests.
See
HTTPRequestHandler
for more information
-
handle: function that implements
HTTPRequestHandler
and is called when a new HTTP request is received by the HTTP server.See
HTTPRequestHandler
for more informationDeclaration
Swift
func handle(request: HTTPRequest, response: HTTPResponseWriter) -> HTTPBodyProcessing
Parameters
request
the incoming HTTP request.
response
a writer providing functions to create an HTTP response to the request.