Smack

org.jivesoftware.smack
Class SmackConfiguration

java.lang.Object
  extended by org.jivesoftware.smack.SmackConfiguration

public final class SmackConfiguration
extends Object

Represents the configuration of Smack. The configuration is used for:

Configuration settings are stored in META-INF/smack-config.xml (typically inside the smack.jar file).

Author:
Gaston Dombiak

Method Summary
static int getKeepAliveInterval()
          Returns the number of milleseconds delay between sending keep-alive requests to the server.
static int getPacketReplyTimeout()
          Returns the number of milliseconds to wait for a response from the server.
static String getVersion()
          Returns the Smack version information, eg "1.3.0".
static void setKeepAliveInterval(int interval)
          Sets the number of milleseconds delay between sending keep-alive requests to the server.
static void setPacketReplyTimeout(int timeout)
          Sets the number of milliseconds to wait for a response from the server.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getVersion

public static String getVersion()
Returns the Smack version information, eg "1.3.0".

Returns:
the Smack version information.

getPacketReplyTimeout

public static int getPacketReplyTimeout()
Returns the number of milliseconds to wait for a response from the server. The default value is 5000 ms.

Returns:
the milliseconds to wait for a response from the server

setPacketReplyTimeout

public static void setPacketReplyTimeout(int timeout)
Sets the number of milliseconds to wait for a response from the server.

Parameters:
timeout - the milliseconds to wait for a response from the server

getKeepAliveInterval

public static int getKeepAliveInterval()
Returns the number of milleseconds delay between sending keep-alive requests to the server. The default value is 30000 ms. A value of -1 mean no keep-alive requests will be sent to the server.

Returns:
the milliseconds to wait between keep-alive requests, or -1 if no keep-alive should be sent.

setKeepAliveInterval

public static void setKeepAliveInterval(int interval)
Sets the number of milleseconds delay between sending keep-alive requests to the server. The default value is 30000 ms. A value of -1 mean no keep-alive requests will be sent to the server.

Parameters:
interval - the milliseconds to wait between keep-alive requests, or -1 if no keep-alive should be sent.

Smack

Copyright © 2003 Jive Software.