Enum Class ConnectionType

java.lang.Object
java.lang.Enum<ConnectionType>
org.jivesoftware.openfire.spi.ConnectionType
All Implemented Interfaces:
Serializable, Comparable<ConnectionType>, Constable

public enum ConnectionType extends Enum<ConnectionType>
Types of (socket-based, including HTTP) connections. This is an enumeration of the connections that are expected to be terminated by an instance of the Openfire instance, and is used to define type-specific characteristics, including but not limited to:
  • Property-name definition
  • Applicable encryption policies
  • Identity & trust store configuration
Author:
Guus der Kinderen, guus.der.kinderen@gmail.com
  • Enum Constant Details

    • SOCKET_S2S

      public static final ConnectionType SOCKET_S2S
      Socket-based server-to-server (XMPP federation) connectivity.
    • SOCKET_C2S

      public static final ConnectionType SOCKET_C2S
      Socket-based client connectivity.
    • BOSH_C2S

      public static final ConnectionType BOSH_C2S
      BOSH (HTTP-bind) based client connectivity.
    • WEBADMIN

      public static final ConnectionType WEBADMIN
      Openfire web-admin console.
    • COMPONENT

      public static final ConnectionType COMPONENT
      Openfire External Component connectivity.
    • CONNECTION_MANAGER

      public static final ConnectionType CONNECTION_MANAGER
      Openfire Connection Manager (multiplexer) connectivity.
  • Method Details

    • values

      public static ConnectionType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ConnectionType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • isClientOriented

      public boolean isClientOriented()
      Flag that indicates whether the connections of this type are client-oriented.
      Returns:
      true if it is SOCKET_C2S or its fallback is SOCKET_C2S.
    • getPrefix

      public String getPrefix()
      Returns the prefix used for the name of properties that are used to configure connections of this type.
      Returns:
      A property name prefix (never null or an empty string).
    • getFallback

      public ConnectionType getFallback()
      Returns a type from which configuration can be used, when configuration specific for this type is missing.
      Returns:
      A configuration fallback, or null if no such fallback exists.