Enum DirectorySession.ConnectionState

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<DirectorySession.ConnectionState>
    Enclosing class:
    DirectorySession

    public static enum DirectorySession.ConnectionState
    extends java.lang.Enum<DirectorySession.ConnectionState>
    Used to report the state of a session: whether and how it is bound. Values here represent the session's state following the most recent directory operation, and are updated whenever an operation is performed.

    Note that if a network connection is lost, then the session state will not become CONNECTION_LOST until the next directory operation is attempted and the problem detected.

    Since:
    14.4
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      CONNECTION_ANONYMOUS
      A DirectorySession is currently bound with no authentication.
      CONNECTION_LOST
      The library has detected that a DirectorySession which was bound has lost its connection.
      CONNECTION_SASL
      A DirectorySession is currently bound using SASL authentication.
      CONNECTION_SIMPLE
      A DirectorySession is currently bound using simple authentication.
      CONNECTION_STATE_UNKNOWN
      The session state is unknown.
      CONNECTION_STRONG
      A DirectorySession is currently bound using strong authentication.
      NOT_YET_CONNECTED
      A DirectorySession object exists but no bind operation has yet been attempted.
      UNBOUND
      A DirectorySession object which was previously bound has been unbound by the user a by calling DirectorySession.unbind().
      VERIFICATION_FAILED
      A connection was attempted over a secured connection, but the certificate presented by the server could not be verified, and so the connection was abandoned.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static DirectorySession.ConnectionState valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static DirectorySession.ConnectionState[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Method Detail

      • values

        public static DirectorySession.ConnectionState[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (DirectorySession.ConnectionState c : DirectorySession.ConnectionState.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static DirectorySession.ConnectionState valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null