Package org.jivesoftware.smack
Interface ReconnectionListener
public interface ReconnectionListener
A listener for the
ReconnectionManager. Use
ReconnectionManager.addReconnectionListener(ReconnectionListener) to add new listeners to the reconnection
manager.- Since:
- 4.2.2
-
Method Summary
Modifier and TypeMethodDescriptionvoidreconnectingIn(int seconds) The connection will retry to reconnect in the specified number of seconds.voidAn attempt to connect to the server has failed.
-
Method Details
-
reconnectingIn
void reconnectingIn(int seconds) The connection will retry to reconnect in the specified number of seconds.Note: This method is only called if
ReconnectionManager.isAutomaticReconnectEnabled()returns true, i.e. only when the reconnection manager is enabled for the connection.- Parameters:
seconds- remaining seconds before attempting a reconnection.
-
reconnectionFailed
An attempt to connect to the server has failed. The connection will keep trying reconnecting to the server in a moment.Note: This method is only called if
ReconnectionManager.isAutomaticReconnectEnabled()returns true, i.e. only when the reconnection manager is enabled for the connection.- Parameters:
e- the exception that caused the reconnection to fail.
-