Package net.sf.saxon.expr.number
Class NumericGroupFormatter
- java.lang.Object
-
- net.sf.saxon.expr.number.NumericGroupFormatter
-
- Direct Known Subclasses:
IrregularGroupFormatter
,RegularGroupFormatter
public abstract class NumericGroupFormatter extends java.lang.Object
A NumericGroupFormatter is responsible for insertion of grouping separators into a formatted number (for example, reformatting "1234" as "1,234").
-
-
Field Summary
Fields Modifier and Type Field Description protected UnicodeString
adjustedPicture
-
Constructor Summary
Constructors Constructor Description NumericGroupFormatter()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract java.lang.String
format(FastStringBuffer value)
Reformat a number to add grouping separatorsUnicodeString
getAdjustedPicture()
Get the adjusted (preprocessed) pictureabstract java.lang.String
getSeparator()
Get the grouping separator to be used, as a Unicode codepoint.
-
-
-
Field Detail
-
adjustedPicture
protected UnicodeString adjustedPicture
-
-
Method Detail
-
getAdjustedPicture
public UnicodeString getAdjustedPicture()
Get the adjusted (preprocessed) picture- Returns:
- the adjusted picture
-
format
public abstract java.lang.String format(FastStringBuffer value)
Reformat a number to add grouping separators- Parameters:
value
- a buffer holding the number to be reformatted- Returns:
- the reformatted number
-
getSeparator
public abstract java.lang.String getSeparator()
Get the grouping separator to be used, as a Unicode codepoint. If more than one is used, return the last. If no grouping separators are used, return null- Returns:
- the grouping separator
-
-