|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.pentaho.reporting.engine.classic.core.function.AbstractExpression
org.pentaho.reporting.engine.classic.core.function.strings.MessageFormatExpression
public class MessageFormatExpression
Formats a message using named parameters. The parameters are resolved against the current data-row.
This performs the same task as the MessageFormatFilter does inside a text-element.
| Constructor Summary | |
|---|---|
MessageFormatExpression()
Default constructor. |
|
| Method Summary | |
|---|---|
String |
getEncoding()
Returns the defined character encoding that is used to transform the Java-Unicode strings into bytes. |
Expression |
getInstance()
Return a completly separated copy of this function. |
String |
getNullString()
Returns the replacement text that is used if one of the referenced message parameters is null. |
String |
getPattern()
Returns the format string used in the message format. |
Object |
getValue()
Returns the formatted message. |
boolean |
isUrlEncodeResult()
Queries, whether the formatted result-string will be URL encoded. |
boolean |
isUrlEncodeValues()
Queries, whether the values read from the data-row should be URL encoded. |
void |
setEncoding(String encoding)
Defines the character encoding that is used to transform the Java-Unicode strings into bytes. |
void |
setNullString(String nullString)
Defines the replacement text that is used if one of the referenced message parameters is null. |
void |
setPattern(String pattern)
Defines the format string for the MessageFormat object used in this implementation. |
void |
setUrlEncodeResult(boolean urlEncodeResult)
Defines, whether the formatted result-string will be URL encoded. |
void |
setUrlEncodeValues(boolean urlEncode)
Defines, whether the values read from the data-row should be URL encoded. |
| Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractExpression |
|---|
clone, getDataRow, getDependencyLevel, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setActive, setDependencyLevel, setName, setPreserve, setRuntime |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MessageFormatExpression()
| Method Detail |
|---|
public String getPattern()
public void setPattern(String pattern)
MessageFormat object used in this implementation.
pattern - the message format.public String getEncoding()
public void setEncoding(String encoding)
encoding - the encoding.public void setUrlEncodeValues(boolean urlEncode)
urlEncode - true, if the values from the data-row should be URL encoded before they are passed to the
MessageFormat, false otherwise.public boolean isUrlEncodeValues()
public boolean isUrlEncodeResult()
public void setUrlEncodeResult(boolean urlEncodeResult)
urlEncodeResult - true, if the formatted result will be encoded, false otherwise.public String getNullString()
public void setNullString(String nullString)
nullString - the replacement text for null-values.public Object getValue()
public Expression getInstance()
AbstractExpression
getInstance in interface ExpressiongetInstance in class AbstractExpression
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||