org.marketcetera.util.except
Class I18NError

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Error
          extended by org.marketcetera.util.except.I18NError
All Implemented Interfaces:
Serializable, I18NThrowable

public class I18NError
extends Error
implements I18NThrowable

An internationalized error.

Since:
0.5.0
Version:
$Id: I18NError.java 16154 2012-07-14 16:34:05Z colin $
Author:
tlerios@marketcetera.com
See Also:
Serialized Form

Constructor Summary
I18NError()
          Constructs a new throwable without a message or an underlying cause.
I18NError(I18NBoundMessage message)
          Constructs a new throwable with the given message, but without an underlying cause.
I18NError(Throwable cause)
          Constructs a new throwable without a message, but with the given underlying cause.
I18NError(Throwable cause, I18NBoundMessage message)
          Constructs a new throwable with the given message and underlying cause.
 
Method Summary
 boolean equals(Object other)
           
 String getDetail()
          Returns the receiver's raw message, possibly combined with the raw message of the receiver's underlying cause.
 I18NBoundMessage getI18NBoundMessage()
          Returns the receiver's message.
 String getLocalizedDetail()
          Returns the receiver's localized message, possibly combined with the localized message of the receiver's underlying cause.
 String getLocalizedMessage()
          Returns the receiver's localized message, as implemented by Throwable.getLocalizedMessage().
 int hashCode()
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getMessage, getStackTrace, 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, getMessage
 

Constructor Detail

I18NError

public I18NError()
Constructs a new throwable without a message or an underlying cause.


I18NError

public I18NError(Throwable cause)
Constructs a new throwable without a message, but with the given underlying cause.

Parameters:
cause - The cause.

I18NError

public I18NError(I18NBoundMessage message)
Constructs a new throwable with the given message, but without an underlying cause.

Parameters:
message - The message.

I18NError

public I18NError(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: I18NThrowable
Returns the receiver's localized message, as implemented by Throwable.getLocalizedMessage().

Specified by:
getLocalizedMessage in interface I18NThrowable
Overrides:
getLocalizedMessage in class Throwable
Returns:
The message. It may be null.

getDetail

public String getDetail()
Description copied from interface: I18NThrowable
Returns the receiver's raw message, possibly combined with the raw message of the receiver's underlying cause.

Specified by:
getDetail in interface I18NThrowable
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: I18NThrowable
Returns the receiver's localized message, possibly combined with the localized message of the receiver's underlying cause.

Specified by:
getLocalizedDetail in interface I18NThrowable
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: I18NThrowable
Returns the receiver's message.

Specified by:
getI18NBoundMessage in interface I18NThrowable
Returns:
The message. It may be null.

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object other)
Overrides:
equals in class Object


Copyright © 2012. All Rights Reserved.