Package info.freelibrary.util
Class I18nException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- info.freelibrary.util.I18nException
-
- All Implemented Interfaces:
Serializable
public class I18nException extends Exception
An I18n'ed exception.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description I18nException()
Constructs a newI18nException
.I18nException(String aBundleName, String aMessageKey)
Constructs a newI18nException
using the supplied bundle details.I18nException(String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the supplied string as the message key and the supplied string varargs as the message details.I18nException(Throwable aCause)
Constructs a newI18nException
with the supplied underlying cause.I18nException(Throwable aCause, String aBundleName, String aMessageKey)
Constructs a newI18nException
with the supplied cause and message.I18nException(Throwable aCause, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the supplied cause, message, and additional details.I18nException(Throwable aCause, Locale aLocale, String aBundleName, String aMessageKey)
Constructs a newI18nException
using theLocale
with the supplied cause and message.I18nException(Throwable aCause, Locale aLocale, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
from the suppliedLocale
with the supplied cause, message, and additional details.I18nException(Locale aLocale, String aBundleName, String aMessageKey)
Constructs a newI18nException
using the suppliedLocale
and bundle details.I18nException(Locale aLocale, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the suppliedLocale
as the locale, the supplied int as the message key, and the supplied string varargs as the message details.
-
Method Summary
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
I18nException
public I18nException()
Constructs a newI18nException
.
-
I18nException
public I18nException(String aBundleName, String aMessageKey)
Constructs a newI18nException
using the supplied bundle details.- Parameters:
aBundleName
- The name of a resource bundle to useaMessageKey
- The message key to retrieve from the supplied bundle
-
I18nException
public I18nException(Locale aLocale, String aBundleName, String aMessageKey)
Constructs a newI18nException
using the suppliedLocale
and bundle details.- Parameters:
aLocale
- TheLocale
to use when looking up the message keyaBundleName
- The name of the resource bundle to useaMessageKey
- The message key whose value should be retrieved from the supplied bundle
-
I18nException
public I18nException(String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the supplied string as the message key and the supplied string varargs as the message details.- Parameters:
aBundleName
- The name of the resource bundle to useaMessageKey
- The message key whose value should be retrieved from the supplied bundleaVarargs
- The additional details to pass into the exception
-
I18nException
public I18nException(Locale aLocale, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the suppliedLocale
as the locale, the supplied int as the message key, and the supplied string varargs as the message details.- Parameters:
aLocale
- The locale to use when constructing the exceptionaBundleName
- The name of the resource bundle to useaMessageKey
- The key to use when looking up the messageaVarargs
- The additional details to pass into the exception
-
I18nException
public I18nException(Throwable aCause)
Constructs a newI18nException
with the supplied underlying cause.- Parameters:
aCause
- The underlying cause of the current exception
-
I18nException
public I18nException(Throwable aCause, String aBundleName, String aMessageKey)
Constructs a newI18nException
with the supplied cause and message.- Parameters:
aCause
- The underlying cause of the current exceptionaBundleName
- The name of the resource bundle to useaMessageKey
- The key to use when looking up the message
-
I18nException
public I18nException(Throwable aCause, Locale aLocale, String aBundleName, String aMessageKey)
Constructs a newI18nException
using theLocale
with the supplied cause and message.- Parameters:
aCause
- The underlying cause of the current exceptionaLocale
- The locale to use when constructing the exceptionaBundleName
- The name of the resource bundle to useaMessageKey
- The key to use when looking up the message
-
I18nException
public I18nException(Throwable aCause, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
with the supplied cause, message, and additional details.- Parameters:
aCause
- The underlying cause of the current exceptionaBundleName
- The name of the resource bundle to useaMessageKey
- The key to use when looking up the messageaVarargs
- The additional details to add to the exception message
-
I18nException
public I18nException(Throwable aCause, Locale aLocale, String aBundleName, String aMessageKey, Object... aVarargs)
Constructs a newI18nException
from the suppliedLocale
with the supplied cause, message, and additional details.- Parameters:
aCause
- The underlying cause of the current exceptionaLocale
- The locale to use when constructing the exceptionaBundleName
- The name of the resource bundle to useaMessageKey
- The key to use when looking up the messageaVarargs
- The additional details to add to the exception message
-
-