Package org.jivesoftware.smack.tcp
Class XMPPTCPConnectionConfiguration
- java.lang.Object
-
- org.jivesoftware.smack.ConnectionConfiguration
-
- org.jivesoftware.smack.tcp.XMPPTCPConnectionConfiguration
-
public final class XMPPTCPConnectionConfiguration extends org.jivesoftware.smack.ConnectionConfigurationA connection configuration for XMPP connections over TCP (the common case).You can get an instance of the configuration builder with
builder()and build the final immutable connection configuration withXMPPTCPConnectionConfiguration.Builder.build().XMPPTCPConnectionConfiguration conf = XMPPTCPConnectionConfiguration.builder() .setXmppDomain("example.org").setUsernameAndPassword("user", "password") .setCompressionEnabled(false).build(); XMPPTCPConnection connection = new XMPPTCPConnection(conf);
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXMPPTCPConnectionConfiguration.BuilderA configuration builder for XMPP connections over TCP.
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_CONNECT_TIMEOUTThe default connect timeout in milliseconds.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static XMPPTCPConnectionConfiguration.Builderbuilder()intgetConnectTimeout()How long the socket will wait until a TCP connection is established (in milliseconds).-
Methods inherited from class org.jivesoftware.smack.ConnectionConfiguration
getAuthzid, getCallbackHandler, getDebuggerFactory, getDnssecMode, getEnabledSaslMechanisms, getEnabledSSLCiphers, getEnabledSSLProtocols, getHost, getHostAddress, getHostnameVerifier, getHostString, getLanguage, getPassword, getPort, getProxyInfo, getResource, getSecurityMode, getServiceName, getSocketFactory, getUsername, getXmlLang, getXMPPServiceDomain, getXmppServiceDomainAsDnsNameIfPossible, isCompressionEnabled, isEnabledSaslMechanism, isSendPresence
-
-
-
-
Method Detail
-
getConnectTimeout
public int getConnectTimeout()
How long the socket will wait until a TCP connection is established (in milliseconds). Defaults toDEFAULT_CONNECT_TIMEOUT.- Returns:
- the timeout value in milliseconds.
-
builder
public static XMPPTCPConnectionConfiguration.Builder builder()
-
-