@Override public void connect() { connectionID = "dummy-" + new Random(new Date().getTime()).nextInt(); if (reconnect) { for (ConnectionListener listener : getConnectionListeners()) { listener.reconnectionSuccessful(); } } }
@Override public void disconnect(Presence unavailablePresence) { user = null; connectionID = null; roster = null; authenticated = false; anonymous = false; for (ConnectionListener listener : getConnectionListeners()) { listener.connectionClosed(); } reconnect = true; }