mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-09-09 09:09:38 +02:00
Use Jid (and subclasses) from jxmpp-jid
Fixes SMACK-634
This commit is contained in:
parent
0ee2d9ed1e
commit
5bb4727c57
180 changed files with 1510 additions and 1032 deletions
|
@ -24,6 +24,7 @@ import org.jivesoftware.smack.XMPPException.XMPPErrorException;
|
|||
import org.jivesoftware.smack.SmackException.NotConnectedException;
|
||||
import org.jivesoftware.smackx.disco.ServiceDiscoveryManager;
|
||||
import org.jivesoftware.smackx.hoxt.packet.AbstractHttpOverXmpp;
|
||||
import org.jxmpp.jid.Jid;
|
||||
|
||||
/**
|
||||
* Manager for HTTP ove XMPP transport (XEP-0332) extension.
|
||||
|
@ -58,7 +59,7 @@ public class HOXTManager {
|
|||
* @throws NotConnectedException
|
||||
* @throws InterruptedException
|
||||
*/
|
||||
public static boolean isSupported(String jid, XMPPConnection connection) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
|
||||
public static boolean isSupported(Jid jid, XMPPConnection connection) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
|
||||
return ServiceDiscoveryManager.getInstanceFor(connection).supportsFeature(jid, NAMESPACE);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,6 +17,8 @@
|
|||
package org.jivesoftware.smackx.carbons;
|
||||
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertThat;
|
||||
import static org.jivesoftware.smack.test.util.CharsequenceEquals.equalsCharSequence;
|
||||
|
||||
import java.util.Properties;
|
||||
|
||||
|
@ -62,7 +64,7 @@ public class CarbonTest extends ExperimentalInitializerTest {
|
|||
assertEquals(null, fwd.getDelayInformation());
|
||||
|
||||
// check message
|
||||
assertEquals("romeo@montague.com", fwd.getForwardedPacket().getFrom());
|
||||
assertThat("romeo@montague.com", equalsCharSequence(fwd.getForwardedPacket().getFrom()));
|
||||
|
||||
// check end of tag
|
||||
assertEquals(XmlPullParser.END_TAG, parser.getEventType());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue