Interface IDisconnectCallback
public interface IDisconnectCallback
Callback interface which can be used to get notified about connection losses.
- Version:
- 4.1.0 - 2022-02-03
- Author:
- hypfvieh
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidCalled when a client disconnected (only if this is a server/listening connection).default voidCalled when the connection is closed due to a connection error (e.g. stream closed).default voidCalled when the transport throws an exception while connection was already terminating.default voidrequestedDisconnect(Integer _connectionId) Called when the disconnect was intended.
-
Method Details
-
disconnectOnError
Called when the connection is closed due to a connection error (e.g. stream closed).- Parameters:
_ex- exception which was thrown by transport
-
requestedDisconnect
Called when the disconnect was intended.- Parameters:
_connectionId- connection Id if this was a shared connection, null if last shared or non-shared connection
-
clientDisconnect
default void clientDisconnect()Called when a client disconnected (only if this is a server/listening connection). -
exceptionOnTerminate
Called when the transport throws an exception while connection was already terminating.- Parameters:
_ex- exception which was thrown by transport
-