1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2025-09-10 01:29:38 +02:00

Refactor reconnection callbacks into an extra class

Fixes SMACK-775
This commit is contained in:
Florian Schmaus 2017-11-25 15:34:05 +01:00
parent d804d4ed6d
commit 2edbc64957
12 changed files with 176 additions and 50 deletions

View file

@ -88,6 +88,7 @@ public class DummyConnection extends AbstractXMPPConnection {
user = getUserJid();
}
@SuppressWarnings("deprecation")
@Override
protected void connectInternal() {
connected = true;
@ -95,6 +96,7 @@ public class DummyConnection extends AbstractXMPPConnection {
tlsHandled.reportSuccess();
streamId = "dummy-" + new Random(new Date().getTime()).nextInt();
// TODO: Remove in Smack 4.3, and likely the suppression of the deprecation warning.
if (reconnect) {
notifyReconnection();
}