public class FastMessageFormat extends Object implements FastFormat
Constructor and Description |
---|
FastMessageFormat(String pattern)
Creates a new default message format object for the given pattern using the default locale as locale.
|
FastMessageFormat(String pattern,
Locale locale)
Creates a new default message format object for the given pattern and locale.
|
FastMessageFormat(String pattern,
Locale locale,
TimeZone timeZone) |
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Clones the formatter.
|
String |
format(Object parameters)
Formats the given object in a formatter-specific way.
|
Locale |
getLocale()
Returns the current locale of the formatter.
|
String |
getNullString()
Returns the null-string that is used whenever a parameter object is null.
|
String |
getPattern()
Returns the currently active pattern.
|
int |
getSubFormatCount()
Returns the number of subformats in the message-formatter.
|
TimeZone |
getTimeZone()
Returns the current time-zone for date formats.
|
void |
setNullString(String nullString)
Defines the null-string that is used whenever a parameter object is null.
|
public FastMessageFormat(String pattern)
pattern
- the pattern.public FastMessageFormat(String pattern, Locale locale)
pattern
- the pattern.locale
- the locale.public int getSubFormatCount()
public Locale getLocale()
getLocale
in interface FastFormat
public TimeZone getTimeZone()
public String getPattern()
public String getNullString()
public void setNullString(String nullString)
nullString
- the nullstring, never null in itself.public String format(Object parameters)
format
in interface FastFormat
parameters
- the parameters for the formatting.public Object clone() throws CloneNotSupportedException
clone
in interface FastFormat
clone
in class Object
CloneNotSupportedException
- if cloning failed.