WebsocketResource Class Reference
Class associated with an open websocket to handle communications. More...
#include <WebsocketResource.h>
Inheritance diagram for WebsocketResource:
Collaboration diagram for WebsocketResource:
Public Member Functions | |
| WebsocketResource () | |
| virtual int | checkHeaders (HttpServerConnection &connection, HttpRequest &request, HttpResponse &response) |
| void | shutdown (HttpServerConnection &connection) override |
| Takes care to cleanup the connection. More... | |
| void | setConnectionHandler (WebsocketDelegate handler) |
| void | setMessageHandler (WebsocketMessageDelegate handler) |
| void | setBinaryHandler (WebsocketBinaryDelegate handler) |
| void | setPongHandler (WebsocketDelegate handler) |
| void | setDisconnectionHandler (WebsocketDelegate handler) |
Public Member Functions inherited from HttpResource | |
| virtual | ~HttpResource () |
| void | addPlugin (HttpResourcePlugin *plugin) |
| template<class... Tail> | |
| void | addPlugin (HttpResourcePlugin *plugin, Tail... plugins) |
Protected Member Functions | |
| bool | onConnect () |
Protected Attributes | |
| WebsocketDelegate | wsConnect = nullptr |
| WebsocketMessageDelegate | wsMessage = nullptr |
| WebsocketBinaryDelegate | wsBinary = nullptr |
| WebsocketDelegate | wsPong = nullptr |
| WebsocketDelegate | wsDisconnect = nullptr |
Additional Inherited Members | |
Public Attributes inherited from HttpResource | |
| HttpResourceDelegate | onUrlComplete = nullptr |
| URL is ready. Path and status code are available. More... | |
| HttpServerConnectionBodyDelegate | onBody = nullptr |
| resource wants to process the raw body data More... | |
| HttpResourceDelegate | onHeadersComplete = nullptr |
| headers are ready More... | |
| HttpResourceDelegate | onRequestComplete = nullptr |
| request is complete OR upgraded More... | |
| HttpServerConnectionUpgradeDelegate | onUpgrade = nullptr |
| request is upgraded and raw data is passed to it More... | |
Detailed Description
Class associated with an open websocket to handle communications.
Constructor & Destructor Documentation
◆ WebsocketResource()
|
inline |
Member Function Documentation
◆ checkHeaders()
|
virtual |
◆ onConnect()
|
protected |
◆ setBinaryHandler()
|
inline |
◆ setConnectionHandler()
|
inline |
◆ setDisconnectionHandler()
|
inline |
◆ setMessageHandler()
|
inline |
◆ setPongHandler()
|
inline |
◆ shutdown()
|
overridevirtual |
Takes care to cleanup the connection.
Reimplemented from HttpResource.
Member Data Documentation
◆ wsBinary
|
protected |
◆ wsConnect
|
protected |
◆ wsDisconnect
|
protected |
◆ wsMessage
|
protected |
◆ wsPong
|
protected |
The documentation for this class was generated from the following file:
Public Member Functions inherited from
1.8.17