Class SessionException

  • All Implemented Interfaces:
    com.sun.identity.shared.locale.L10NMessage, Serializable

    @SupportedAll
    public class SessionException
    extends com.sun.identity.shared.locale.L10NMessageImpl
    This class is to handle Session related exceptions.
    See Also:
    Serialized Form
    • Field Detail

      • AUTH_ERROR_NOT_DEFINED

        public static int AUTH_ERROR_NOT_DEFINED
        Error codes.
      • AUTH_USER_INACTIVE

        public static int AUTH_USER_INACTIVE
      • AUTH_USER_LOCKED

        public static int AUTH_USER_LOCKED
      • AUTH_ACCOUNT_EXPIRED

        public static int AUTH_ACCOUNT_EXPIRED
    • Constructor Detail

      • SessionException

        public SessionException​(String message)
        Constructs a SessionException with a detailed message.
        Parameters:
        message - Detailed message for this exception.
      • SessionException

        public SessionException​(Throwable rootCause)
        Constructs a SessionException with an embedded exception.
        Parameters:
        rootCause - An embedded exception
      • SessionException

        public SessionException​(Exception ex)
        Constructs a SessionException with an exception.
        Parameters:
        ex - an exception
      • SessionException

        public SessionException​(String rbName,
                                String messageKey,
                                Object[] args)
        Constructs a new SessionException without a nested Throwable.
        Parameters:
        rbName - Resource Bundle Name to be used for getting localized error message.
        messageKey - Key to resource bundle. You can use
         ResourceBundle rb = ResourceBunde.getBundle (rbName,locale);
         String localizedStr = rb.getString(messageCode);
         
        args - arguments to message. If it is not present pass them as null
    • Method Detail

      • getErrCode

        public int getErrCode()
        Returns the error code for the caller of a SessionProvider method.
        Returns:
        Error code.
      • setErrCode

        public void setErrCode​(int errorCode)
        Sets an error code by an implementation of the SessionProvider to indicate a specific error condition which could be retrieved by the caller of a SessionProvider method.
        Parameters:
        errorCode - the error code to be set.