mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 17:19:39 +02:00
Add SubscribeAnswer.ApproveAndAlsoRequestIfRequired
This commit is contained in:
parent
9a34e9e870
commit
65b4f506dc
7 changed files with 50 additions and 13 deletions
|
@ -46,6 +46,7 @@ import org.jivesoftware.smack.SmackException.AlreadyConnectedException;
|
|||
import org.jivesoftware.smack.SmackException.AlreadyLoggedInException;
|
||||
import org.jivesoftware.smack.SmackException.NoResponseException;
|
||||
import org.jivesoftware.smack.SmackException.NotConnectedException;
|
||||
import org.jivesoftware.smack.SmackException.NotLoggedInException;
|
||||
import org.jivesoftware.smack.SmackException.ResourceBindingNotOfferedException;
|
||||
import org.jivesoftware.smack.SmackException.SecurityRequiredByClientException;
|
||||
import org.jivesoftware.smack.SmackException.SecurityRequiredException;
|
||||
|
@ -1527,7 +1528,7 @@ public abstract class AbstractXMPPConnection implements XMPPConnection {
|
|||
|
||||
final StanzaListener packetListener = new StanzaListener() {
|
||||
@Override
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException {
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException, NotLoggedInException {
|
||||
boolean removed = removeAsyncStanzaListener(this);
|
||||
if (!removed) {
|
||||
// We lost a race against the "no response" handling runnable. Avoid calling the callback, as the
|
||||
|
@ -1591,7 +1592,7 @@ public abstract class AbstractXMPPConnection implements XMPPConnection {
|
|||
public void addOneTimeSyncCallback(final StanzaListener callback, final StanzaFilter packetFilter) {
|
||||
final StanzaListener packetListener = new StanzaListener() {
|
||||
@Override
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException {
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException, NotLoggedInException {
|
||||
try {
|
||||
callback.processStanza(packet);
|
||||
} finally {
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
package org.jivesoftware.smack;
|
||||
|
||||
import org.jivesoftware.smack.SmackException.NotConnectedException;
|
||||
import org.jivesoftware.smack.SmackException.NotLoggedInException;
|
||||
import org.jivesoftware.smack.packet.Stanza;
|
||||
|
||||
/**
|
||||
|
@ -49,7 +50,8 @@ public interface StanzaListener {
|
|||
* @param packet the stanza(/packet) to process.
|
||||
* @throws NotConnectedException
|
||||
* @throws InterruptedException
|
||||
* @throws NotLoggedInException
|
||||
*/
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException;
|
||||
public void processStanza(Stanza packet) throws NotConnectedException, InterruptedException, NotLoggedInException;
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue