com.flexive.shared.exceptions
Class FxExceptionMessage

java.lang.Object
  extended by com.flexive.shared.exceptions.FxExceptionMessage
All Implemented Interfaces:
java.io.Serializable

public class FxExceptionMessage
extends java.lang.Object
implements java.io.Serializable

Localized Exception message handling

Author:
Markus Plesser (markus.plesser@flexive.com), UCS - unique computing solutions gmbh (http://www.ucs.at)
See Also:
Serialized Form

Constructor Summary
FxExceptionMessage(java.lang.String key, java.lang.Object... values)
          Ctor
 
Method Summary
 boolean equals(java.lang.Object obj)
          
 java.lang.String getKey()
          Getter for the key
 java.lang.String getLocalizedMessage(FxLanguage locale)
          Get the localized message for a given language
 java.lang.String getLocalizedMessage(long localeId)
          Get the localized message for a given language code
 java.lang.String getLocalizedMessage(long localeId, java.lang.String localeIso)
          Get the localized message for a given language code and ISO
 java.lang.String getLocalizedMessage(java.lang.String localeIso)
          Get the localized message for given ISO code
 int hashCode()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FxExceptionMessage

public FxExceptionMessage(java.lang.String key,
                          java.lang.Object... values)
Ctor

Parameters:
key - resource key
values - optional values for placeholders in key ({x})
Method Detail

getKey

public java.lang.String getKey()
Getter for the key

Returns:
key resource key

getLocalizedMessage

public java.lang.String getLocalizedMessage(long localeId)
Get the localized message for a given language code

Parameters:
localeId - locale id of the desired output
Returns:
localized message

getLocalizedMessage

public java.lang.String getLocalizedMessage(java.lang.String localeIso)
Get the localized message for given ISO code

Parameters:
localeIso - requested ISO code for desired output
Returns:
localized message

getLocalizedMessage

public java.lang.String getLocalizedMessage(FxLanguage locale)
Get the localized message for a given language

Parameters:
locale - locale of the desired output
Returns:
localized message

getLocalizedMessage

public java.lang.String getLocalizedMessage(long localeId,
                                            java.lang.String localeIso)
Get the localized message for a given language code and ISO

Parameters:
localeId - id of the requested locale
localeIso - ISO code of the requested locale
Returns:
localized message

equals

public boolean equals(java.lang.Object obj)

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object