HttpResource.h
Go to the documentation of this file.
86 int handleHeaders(HttpServerConnection& connection, HttpRequest& request, HttpResponse& response);
87 int handleUpgrade(HttpServerConnection& connection, HttpRequest& request, char* data, size_t length);
88 int handleBody(HttpServerConnection& connection, HttpRequest& request, char*& data, size_t& length);
89 int handleRequest(HttpServerConnection& connection, HttpRequest& request, HttpResponse& response);
Definition: HttpResource.h:48
Base class template for linked items with type casting.
Definition: LinkedObject.h:61
HttpResourceDelegate onRequestComplete
request is complete OR upgraded
Definition: HttpResource.h:69
Represents either an incoming or outgoing response to a HTTP request.
Definition: HttpResponse.h:25
Base plugin class. Implementations should be based on either HttpPreFilter or HttpPostFilter
Definition: HttpResourcePlugin.h:23
void addPlugin(HttpResourcePlugin *plugin)
HttpServerConnectionUpgradeDelegate onUpgrade
request is upgraded and raw data is passed to it
Definition: HttpResource.h:70
PluginRef(HttpResourcePlugin *plugin)
Definition: HttpResource.h:53
void addPlugin(HttpResourcePlugin *plugin, Tail... plugins)
Definition: HttpResource.h:74
HttpResourceDelegate onUrlComplete
URL is ready. Path and status code are available.
Definition: HttpResource.h:66
virtual void shutdown(HttpServerConnection &connection)
Takes care to cleanup the connection.
Definition: HttpResource.h:43
Instances of this class are registered with an HttpServer for a specific URL.
Definition: HttpResource.h:33
HttpResourceDelegate onHeadersComplete
headers are ready
Definition: HttpResource.h:68
Definition: HttpServerConnection.h:33
HttpResourcePlugin * operator->() const
Definition: HttpResource.h:57
HttpServerConnectionBodyDelegate onBody
resource wants to process the raw body data
Definition: HttpResource.h:67