Adding close() method. It abruptly closes the socket (does not bother to send a

CLOSE message prior to actually closing the socket).
This commit is contained in:
David Baird
2013-04-27 23:26:19 -06:00
parent f75e79b1ff
commit f7d998481c
3 changed files with 16 additions and 5 deletions
+1
View File
@@ -23,6 +23,7 @@ struct WebSocket {
virtual ~WebSocket() { }
virtual void poll() = 0;
virtual void send(std::string message) = 0;
virtual void close() = 0;
template<class Callable>
void dispatch(Callable callable) { // N.B. this is compatible with both C++11 lambdas, functors and C function pointers
struct _Callback : public Callback {