public class MessageFormatSupport extends Object implements Serializable, Cloneable
Modifier and Type | Class and Description |
---|---|
protected static class |
MessageFormatSupport.MessageCompiler
The message compiler maps all named references into numeric references.
|
Constructor and Description |
---|
MessageFormatSupport()
Default Constructor.
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Creates a copy of this message format support object.
|
String |
getCompiledFormat()
Returns the compiled message format string.
|
String[] |
getFields() |
String |
getFormatString()
Returns the original format string that is used to format the fields.
|
Locale |
getLocale()
Returns the locale that is used to format the messages.
|
String |
getNullString()
Returns the replacement text that is used if one of the referenced message parameters is null.
|
TimeZone |
getTimeZone() |
String |
performFormat(DataRow dataRow)
Formats the message using the fields from the given data-row as values for the parameters.
|
void |
setFormatString(String formatString)
Updates the named format string and compiles a new field list and message-format string.
|
void |
setLocale(Locale locale)
Updates the locale that is used to format the messages.
|
void |
setNullString(String nullString)
Defines the replacement text that is used if one of the referenced message parameters is null.
|
void |
setTimeZone(TimeZone timeZone) |
public String getFormatString()
public void setFormatString(String formatString)
formatString
- the format string.public String performFormat(DataRow dataRow)
dataRow
- the data row.public String getCompiledFormat()
public Locale getLocale()
public void setLocale(Locale locale)
locale
- the locale in the message format.public TimeZone getTimeZone()
public void setTimeZone(TimeZone timeZone)
public String getNullString()
public void setNullString(String nullString)
nullString
- the replacement text for null-values.public String[] getFields()
public Object clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
- if an error occured.Copyright © 2002–2017 Pentaho Corporation. All rights reserved.