aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorpaweldomas <pawel.domas@jitsi.org>2016-12-28 10:37:29 -0600
committerpaweldomas <pawel.domas@jitsi.org>2016-12-28 11:34:20 -0600
commitd52a2f32834186b3774800dac0674d56c5cbafb8 (patch)
tree4a72b1cb355601d8fc25ee053ab50b6580f7b99f /src
parent3805f9507a3931f34067fcb64ae28e6f69d44fcc (diff)
downloadjitsi-d52a2f32834186b3774800dac0674d56c5cbafb8.zip
jitsi-d52a2f32834186b3774800dac0674d56c5cbafb8.tar.gz
jitsi-d52a2f32834186b3774800dac0674d56c5cbafb8.tar.bz2
Adds BOSH_URL property to JabberAccountID
Diffstat (limited to 'src')
-rw-r--r--src/net/java/sip/communicator/service/protocol/jabber/JabberAccountID.java29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/net/java/sip/communicator/service/protocol/jabber/JabberAccountID.java b/src/net/java/sip/communicator/service/protocol/jabber/JabberAccountID.java
index 81473c2..dce28d6 100644
--- a/src/net/java/sip/communicator/service/protocol/jabber/JabberAccountID.java
+++ b/src/net/java/sip/communicator/service/protocol/jabber/JabberAccountID.java
@@ -44,6 +44,12 @@ public class JabberAccountID
public static final String ANONYMOUS_AUTH = "ANONYMOUS_AUTH";
/**
+ * Configures the URL which is to be used with BOSH transport. If the value
+ * is <tt>null</tt> or empty then the TCP transport will be used instead.
+ */
+ public static final String BOSH_URL = "BOSH_URL";
+
+ /**
* Account suffix for Google service.
*/
public static final String GOOGLE_USER_SUFFIX = "gmail.com";
@@ -119,6 +125,29 @@ public class JabberAccountID
}
/**
+ * Returns the BOSH URL which should be used to connect to the XMPP server.
+ * If the value is set then BOSH transport instead of TCP will be used.
+ *
+ * @return a <tt>String</tt> with the URL which should be used for BOSH
+ * transport or <tt>null</tt> if disabled.
+ */
+ public String getBoshUrl()
+ {
+ return getAccountPropertyString(BOSH_URL);
+ }
+
+ /**
+ * Sets new URL which should be used for the BOSH transport.
+ *
+ * @param boshPath a <tt>String</tt> with the new BOSH URL or <tt>null</tt>
+ * to disable BOSH.
+ */
+ public void setBoshUrl(String boshPath)
+ {
+ putAccountProperty(BOSH_URL, boshPath);
+ }
+
+ /**
* Returns the override phone suffix.
*
* @return the phone suffix