Package org.dellroad.stuff.text
Class MessageFmt.PercentArgumentSegment
java.lang.Object
org.dellroad.stuff.text.MessageFmt.Segment
org.dellroad.stuff.text.MessageFmt.ArgumentSegment
org.dellroad.stuff.text.MessageFmt.FormatArgumentSegment<T>
org.dellroad.stuff.text.MessageFmt.NumberFormatArgumentSegment<NumberFormat>
org.dellroad.stuff.text.MessageFmt.PercentArgumentSegment
- Enclosing class:
- MessageFmt
public static class MessageFmt.PercentArgumentSegment
extends MessageFmt.NumberFormatArgumentSegment<NumberFormat>
An
MessageFmt.ArgumentSegment
that formats its argument using the NumberFormat
percent instance for the locale.- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected String
Get theMessageFormat
pattern string argument suffix, if any.void
visit
(MessageFmt.SegmentSwitch target) Visit the method of the given switch corresponding to this instance's concrete type.Methods inherited from class org.dellroad.stuff.text.MessageFmt.FormatArgumentSegment
of
Methods inherited from class org.dellroad.stuff.text.MessageFmt.ArgumentSegment
equals, getArgumentNumber, hashCode, setArgumentNumber, toPattern, toString
-
Constructor Details
-
PercentArgumentSegment
public PercentArgumentSegment() -
PercentArgumentSegment
public PercentArgumentSegment(int argumentNumber)
-
-
Method Details
-
getArgumentSuffix
Description copied from class:MessageFmt.ArgumentSegment
Get theMessageFormat
pattern string argument suffix, if any.If present, this suffix follows the argument number and a comma, and precedes the closing curly brace.
- Specified by:
getArgumentSuffix
in classMessageFmt.ArgumentSegment
- Returns:
- pattern string argument suffix, or null if none needed
-
visit
Description copied from class:MessageFmt.Segment
Visit the method of the given switch corresponding to this instance's concrete type.- Specified by:
visit
in classMessageFmt.Segment
- Parameters:
target
- visitor pattern target
-