public class AdvancedMessageFormatter extends AbstractMessageFormatter
Unlike LegacyMessageFormatter
, choice format and decimal format compatible patterns can be used in
placeholders, and curly brackets can be escaped by a backslash.
ADDITIONAL_STRING_BUILDER_CAPACITY
Constructor and Description |
---|
AdvancedMessageFormatter(Locale locale,
boolean escape) |
Modifier and Type | Method and Description |
---|---|
String |
format(String message,
Object[] arguments)
Formats a text message.
|
resolve, resolve
public AdvancedMessageFormatter(Locale locale, boolean escape)
locale
- Locale for formatting numbersescape
- true
to enable escaping by ticks, false
to disablepublic String format(String message, Object[] arguments)
MessageFormatter
message
- Text message with placeholdersarguments
- Replacements for placeholdersCopyright © 2024. All rights reserved.