|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.iscreen.mvel.MvelMessage
public class MvelMessage
Field Summary | |
---|---|
protected java.lang.Object |
contextBean
|
protected java.util.Map |
extraMessages
|
protected int |
severityLevel
|
protected java.lang.String |
template
|
Constructor Summary | |
---|---|
protected |
MvelMessage()
For sub-classes to over-ride how this works. |
|
MvelMessage(java.lang.String theTemplate,
int severity)
Default constructor. |
Method Summary | |
---|---|
void |
addMessage(java.lang.String name,
MvelMessage extraMessage)
Adds an additional message. |
java.lang.Object |
getContextBean()
Returns the OGNL root previously set using the setOgnlRoot() method. |
java.util.Map |
getExtraMessages()
Retrieves additional messages that are associated with the failure. |
java.lang.String |
getMessage()
Generates a message based upon the template of this message and the OGNL root passed in to the setOgnlRoot() method. |
java.lang.String |
getMessage(java.lang.Object context,
java.util.Locale locale)
Generates a message based upon the template of this message and the OGNL root passed in. |
int |
getSeverity()
Retrieves the failure's severity level. |
java.lang.String |
getTemplate(java.util.Locale locale)
Returns the template previously set during construction. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected java.lang.String template
protected java.lang.Object contextBean
protected int severityLevel
protected java.util.Map extraMessages
Constructor Detail |
---|
public MvelMessage(java.lang.String theTemplate, int severity)
protected MvelMessage()
Method Detail |
---|
public java.lang.String getMessage()
public java.util.Map getExtraMessages()
FailureMessage
getExtraMessages
in interface FailureMessage
public void addMessage(java.lang.String name, MvelMessage extraMessage)
name
- The name of the message.extraMessage
- The extra message.public java.lang.String getMessage(java.lang.Object context, java.util.Locale locale)
getMessage
in interface FailureMessage
context
- The OGNL root to use for generating the message.locale
- The locale use for localizing the message.
public int getSeverity()
FailureMessage
getSeverity
in interface FailureMessage
public java.lang.Object getContextBean()
public java.lang.String getTemplate(java.util.Locale locale)
locale
- The locale to use.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |