Package org.marketcetera.util.except
Class I18NException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.marketcetera.util.except.I18NException
-
- All Implemented Interfaces:
Serializable,I18NThrowable
- Direct Known Subclasses:
I18NInterruptedException,SessionExpiredException,SessionRequiredException
public class I18NException extends RuntimeException implements I18NThrowable
An internationalized exception.- Since:
- 0.5.0
- Version:
- $Id: I18NException.java 17411 2017-04-28 14:50:38Z colin $
- Author:
- tlerios@marketcetera.com
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private I18NBoundMessagemMessageprivate static longserialVersionUID
-
Constructor Summary
Constructors Constructor Description I18NException()Constructs a new throwable without a message or an underlying cause.I18NException(Throwable cause)Constructs a new throwable without a message, but with the given underlying cause.I18NException(Throwable cause, I18NBoundMessage message)Constructs a new throwable with the given message and underlying cause.I18NException(I18NBoundMessage message)Constructs a new throwable with the given message, but without an underlying cause.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object other)StringgetDetail()Returns the receiver's raw message, possibly combined with the raw message of the receiver's underlying cause.I18NBoundMessagegetI18NBoundMessage()Returns the receiver's message.StringgetLocalizedDetail()Returns the receiver's localized message, possibly combined with the localized message of the receiver's underlying cause.StringgetLocalizedMessage()Returns the receiver's localized message, as implemented byThrowable.getLocalizedMessage().StringgetMessage()Returns the receiver's raw message, as implemented byThrowable.getMessage().inthashCode()-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.marketcetera.util.except.I18NThrowable
getCause
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
mMessage
private I18NBoundMessage mMessage
-
-
Constructor Detail
-
I18NException
public I18NException()
Constructs a new throwable without a message or an underlying cause.
-
I18NException
public I18NException(Throwable cause)
Constructs a new throwable without a message, but with the given underlying cause.- Parameters:
cause- The cause.
-
I18NException
public I18NException(I18NBoundMessage message)
Constructs a new throwable with the given message, but without an underlying cause.- Parameters:
message- The message.
-
I18NException
public I18NException(Throwable cause, I18NBoundMessage message)
Constructs a new throwable with the given message and underlying cause.- Parameters:
cause- The cause.message- The message.
-
-
Method Detail
-
getLocalizedMessage
public String getLocalizedMessage()
Description copied from interface:I18NThrowableReturns the receiver's localized message, as implemented byThrowable.getLocalizedMessage().- Specified by:
getLocalizedMessagein interfaceI18NThrowable- Overrides:
getLocalizedMessagein classThrowable- Returns:
- The message. It may be null.
-
getMessage
public String getMessage()
Description copied from interface:I18NThrowableReturns the receiver's raw message, as implemented byThrowable.getMessage().- Specified by:
getMessagein interfaceI18NThrowable- Overrides:
getMessagein classThrowable- Returns:
- The message. It may be null.
-
getDetail
public String getDetail()
Description copied from interface:I18NThrowableReturns the receiver's raw message, possibly combined with the raw message of the receiver's underlying cause.- Specified by:
getDetailin interfaceI18NThrowable- Returns:
- The message. It may be null if there is no raw message for the receiver, and no underlying cause message.
-
getLocalizedDetail
public String getLocalizedDetail()
Description copied from interface:I18NThrowableReturns the receiver's localized message, possibly combined with the localized message of the receiver's underlying cause.- Specified by:
getLocalizedDetailin interfaceI18NThrowable- Returns:
- The message. It may be null if there is no localized message for the receiver, and no underlying localized cause message.
-
getI18NBoundMessage
public I18NBoundMessage getI18NBoundMessage()
Description copied from interface:I18NThrowableReturns the receiver's message.- Specified by:
getI18NBoundMessagein interfaceI18NThrowable- Returns:
- The message. It may be null.
-
-