public final class LocalizedMessage extends Object implements Comparable<LocalizedMessage>, Serializable
Constructor and Description |
---|
LocalizedMessage(int aLineNo,
int aColNo,
String aBundle,
String aKey,
Object[] aArgs,
SeverityLevel aSeverityLevel,
String aModuleId,
Class<?> aSourceClass,
String aCustomMessage)
Creates a new
LocalizedMessage instance. |
LocalizedMessage(int aLineNo,
int aColNo,
String aBundle,
String aKey,
Object[] aArgs,
String aModuleId,
Class<?> aSourceClass,
String aCustomMessage)
Creates a new
LocalizedMessage instance. |
LocalizedMessage(int aLineNo,
String aBundle,
String aKey,
Object[] aArgs,
SeverityLevel aSeverityLevel,
String aModuleId,
Class<?> aSourceClass,
String aCustomMessage)
Creates a new
LocalizedMessage instance. |
LocalizedMessage(int aLineNo,
String aBundle,
String aKey,
Object[] aArgs,
String aModuleId,
Class<?> aSourceClass,
String aCustomMessage)
Creates a new
LocalizedMessage instance. |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(LocalizedMessage aOther) |
boolean |
equals(Object aObject) |
int |
getColumnNo() |
String |
getKey()
Returns the message key to locate the translation, can also be used
in IDE plugins to map error messages to corrective actions.
|
int |
getLineNo() |
String |
getMessage() |
String |
getModuleId() |
SeverityLevel |
getSeverityLevel() |
String |
getSourceName() |
int |
hashCode() |
static void |
setLocale(Locale aLocale) |
public LocalizedMessage(int aLineNo, int aColNo, String aBundle, String aKey, Object[] aArgs, SeverityLevel aSeverityLevel, String aModuleId, Class<?> aSourceClass, String aCustomMessage)
LocalizedMessage
instance.aLineNo
- line number associated with the messageaColNo
- column number associated with the messageaBundle
- resource bundle nameaKey
- the key to locate the translationaArgs
- arguments for the translationaSeverityLevel
- severity level for the messageaModuleId
- the id of the module the message is associated withaSourceClass
- the Class that is the source of the messageaCustomMessage
- optional custom message overriding the defaultpublic LocalizedMessage(int aLineNo, int aColNo, String aBundle, String aKey, Object[] aArgs, String aModuleId, Class<?> aSourceClass, String aCustomMessage)
LocalizedMessage
instance.aLineNo
- line number associated with the messageaColNo
- column number associated with the messageaBundle
- resource bundle nameaKey
- the key to locate the translationaArgs
- arguments for the translationaModuleId
- the id of the module the message is associated withaSourceClass
- the Class that is the source of the messageaCustomMessage
- optional custom message overriding the defaultpublic LocalizedMessage(int aLineNo, String aBundle, String aKey, Object[] aArgs, SeverityLevel aSeverityLevel, String aModuleId, Class<?> aSourceClass, String aCustomMessage)
LocalizedMessage
instance.aLineNo
- line number associated with the messageaBundle
- resource bundle nameaKey
- the key to locate the translationaArgs
- arguments for the translationaSeverityLevel
- severity level for the messageaModuleId
- the id of the module the message is associated withaSourceClass
- the source class for the messageaCustomMessage
- optional custom message overriding the defaultpublic LocalizedMessage(int aLineNo, String aBundle, String aKey, Object[] aArgs, String aModuleId, Class<?> aSourceClass, String aCustomMessage)
LocalizedMessage
instance. The column number
defaults to 0.aLineNo
- line number associated with the messageaBundle
- name of a resource bundle that contains error messagesaKey
- the key to locate the translationaArgs
- arguments for the translationaModuleId
- the id of the module the message is associated withaSourceClass
- the name of the source for the messageaCustomMessage
- optional custom message overriding the defaultpublic String getMessage()
public int getLineNo()
public int getColumnNo()
public SeverityLevel getSeverityLevel()
public String getModuleId()
public String getKey()
public String getSourceName()
public static void setLocale(Locale aLocale)
aLocale
- the locale to use for localizationpublic int compareTo(LocalizedMessage aOther)
compareTo
in interface Comparable<LocalizedMessage>
Copyright © 2001-2015. All Rights Reserved.