1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2025-09-09 17:19:39 +02:00

Deprecate setServiceName in favor of setXmppDomain

This commit is contained in:
Florian Schmaus 2015-06-08 14:39:05 +02:00
parent 4d7279d036
commit bad52fad21
9 changed files with 22 additions and 10 deletions

View file

@ -464,9 +464,21 @@ public abstract class ConnectionConfiguration {
*
* @param serviceName the service name
* @return a reference to this builder.
* @deprecated use {@link #setXmppDomain(DomainBareJid)} instead.
*/
@Deprecated
public B setServiceName(DomainBareJid serviceName) {
this.xmppServiceDomain = serviceName;
return setXmppDomain(serviceName);
}
/**
* Set the service name of this XMPP service (i.e., the XMPP domain).
*
* @param xmppServiceDomain the service name
* @return a reference to this builder.
*/
public B setXmppDomain(DomainBareJid xmppServiceDomain) {
this.xmppServiceDomain = xmppServiceDomain;
return getThis();
}

View file

@ -57,7 +57,7 @@ public class DummyConnection extends AbstractXMPPConnection {
private final BlockingQueue<TopLevelStreamElement> queue = new LinkedBlockingQueue<TopLevelStreamElement>();
public static ConnectionConfiguration.Builder<?,?> getDummyConfigurationBuilder() {
return DummyConnectionConfiguration.builder().setServiceName(JidTestUtil.EXAMPLE_ORG).setUsernameAndPassword("dummy",
return DummyConnectionConfiguration.builder().setXmppDomain(JidTestUtil.EXAMPLE_ORG).setUsernameAndPassword("dummy",
"dummypass");
}