File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -49,6 +49,7 @@ class ConnectionHandler {
4949
5050 ConnectionHandler (bool const keep_alive=true , NetworkAdapter interface=NetworkAdapter::NONE);
5151
52+ virtual ~ConnectionHandler () {}
5253
5354 NetworkConnectionState check ();
5455
@@ -73,10 +74,10 @@ class ConnectionHandler {
7374 return _interface;
7475 }
7576
76- void connect ();
77- void disconnect ();
77+ virtual void connect ();
78+ virtual void disconnect ();
7879
79- void addCallback (NetworkConnectionEvent const event, OnNetworkEventCallback callback);
80+ virtual void addCallback (NetworkConnectionEvent const event, OnNetworkEventCallback callback);
8081 void addConnectCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
8182 void addDisconnectCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
8283 void addErrorCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
@@ -97,6 +98,8 @@ class ConnectionHandler {
9798 return false ;
9899 }
99100
101+ virtual void setKeepAlive (bool keep_alive=true ) { this ->_keep_alive = keep_alive; }
102+
100103 protected:
101104
102105 bool _keep_alive;
You can’t perform that action at this time.
0 commit comments