Package com.ibm.icu.impl.number
Class Grouper
java.lang.Object
com.ibm.icu.impl.number.Grouper
A full options object for grouping sizes.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate static final Grouperprivate final shortThe primary grouping size, with the following special values: -1 = no grouping -2 = needs locale data -4 = fall back to Western grouping if not in localeprivate final shortThe secondary grouping size, with the following special values: -1 = no grouping -2 = needs locale data -4 = fall back to Western grouping if not in localeprivate final shortThe minimum grouping size, with the following special values: -2 = needs locale data -3 = no less than 2 -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateGrouper(short grouping1, short grouping2, short minGrouping) -
Method Summary
Modifier and TypeMethodDescriptionstatic GrouperforProperties(DecimalFormatProperties properties) Resolve the values in Properties to a Grouper object.static GrouperforStrategy(NumberFormatter.GroupingStrategy grouping) Convert from the GroupingStrategy enum to a Grouper object.static GroupergetInstance(short grouping1, short grouping2, short minGrouping) private static shortgetMinGroupingForLocale(ULocale locale) shortshortbooleangroupAtPosition(int position, DecimalQuantity value) withLocaleData(ULocale locale, PatternStringParser.ParsedPatternInfo patternInfo)
-
Field Details
-
GROUPER_NEVER
-
GROUPER_MIN2
-
GROUPER_AUTO
-
GROUPER_ON_ALIGNED
-
GROUPER_WESTERN
-
GROUPER_INDIC
-
GROUPER_WESTERN_MIN2
-
GROUPER_INDIC_MIN2
-
grouping1
private final short grouping1The primary grouping size, with the following special values:- -1 = no grouping
- -2 = needs locale data
- -4 = fall back to Western grouping if not in locale
-
grouping2
private final short grouping2The secondary grouping size, with the following special values:- -1 = no grouping
- -2 = needs locale data
- -4 = fall back to Western grouping if not in locale
-
minGrouping
private final short minGroupingThe minimum grouping size, with the following special values:- -2 = needs locale data
- -3 = no less than 2
-
-
Constructor Details
-
Grouper
private Grouper(short grouping1, short grouping2, short minGrouping)
-
-
Method Details
-
forStrategy
Convert from the GroupingStrategy enum to a Grouper object. -
forProperties
Resolve the values in Properties to a Grouper object. -
getInstance
-
getMinGroupingForLocale
-
withLocaleData
-
groupAtPosition
-
getPrimary
public short getPrimary() -
getSecondary
public short getSecondary()
-