File tree 1 file changed +6
-3
lines changed
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -49,6 +49,7 @@ class ConnectionHandler {
49
49
50
50
ConnectionHandler (bool const keep_alive=true , NetworkAdapter interface=NetworkAdapter::NONE);
51
51
52
+ virtual ~ConnectionHandler () {}
52
53
53
54
NetworkConnectionState check ();
54
55
@@ -73,10 +74,10 @@ class ConnectionHandler {
73
74
return _interface;
74
75
}
75
76
76
- void connect ();
77
- void disconnect ();
77
+ virtual void connect ();
78
+ virtual void disconnect ();
78
79
79
- void addCallback (NetworkConnectionEvent const event, OnNetworkEventCallback callback);
80
+ virtual void addCallback (NetworkConnectionEvent const event, OnNetworkEventCallback callback);
80
81
void addConnectCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
81
82
void addDisconnectCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
82
83
void addErrorCallback (OnNetworkEventCallback callback) __attribute__((deprecated));
@@ -97,6 +98,8 @@ class ConnectionHandler {
97
98
return false ;
98
99
}
99
100
101
+ virtual void setKeepAlive (bool keep_alive=true ) { this ->_keep_alive = keep_alive; }
102
+
100
103
protected:
101
104
102
105
bool _keep_alive;
You can’t perform that action at this time.
0 commit comments