Package com.sun.identity.plugin.session
Class SessionException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- com.sun.identity.shared.locale.L10NMessageImpl
-
- com.sun.identity.plugin.session.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 Summary
Fields Modifier and Type Field Description static int
AUTH_ACCOUNT_EXPIRED
static int
AUTH_ERROR_NOT_DEFINED
Error codes.static int
AUTH_USER_INACTIVE
static int
AUTH_USER_LOCKED
-
Constructor Summary
Constructors Constructor Description SessionException(Exception ex)
Constructs aSessionException
with an exception.SessionException(String message)
Constructs aSessionException
with a detailed message.SessionException(String rbName, String messageKey, Object[] args)
Constructs a newSessionException
without a nestedThrowable
.SessionException(Throwable rootCause)
Constructs aSessionException
with an embedded exception.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getErrCode()
Returns the error code for the caller of aSessionProvider
method.void
setErrCode(int errorCode)
Sets an error code by an implementation of theSessionProvider
to indicate a specific error condition which could be retrieved by the caller of a SessionProvider method.-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
SessionException
public SessionException(String message)
Constructs aSessionException
with a detailed message.- Parameters:
message
- Detailed message for this exception.
-
SessionException
public SessionException(Throwable rootCause)
Constructs aSessionException
with an embedded exception.- Parameters:
rootCause
- An embedded exception
-
SessionException
public SessionException(Exception ex)
Constructs aSessionException
with an exception.- Parameters:
ex
- an exception
-
SessionException
public SessionException(String rbName, String messageKey, Object[] args)
Constructs a newSessionException
without a nestedThrowable
.- Parameters:
rbName
- Resource Bundle Name to be used for getting localized error message.messageKey
- Key to resource bundle. You can useResourceBundle 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 aSessionProvider
method.- Returns:
- Error code.
-
setErrCode
public void setErrCode(int errorCode)
Sets an error code by an implementation of theSessionProvider
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.
-
-