NumberFormatOptions.compact constructor
NumberFormatOptions.compact({
- CompactDisplay compactDisplay = CompactDisplay.short,
- FormatStyle style = const DecimalStyle(),
- LocaleMatcher localeMatcher = LocaleMatcher.bestfit,
- SignDisplay signDisplay = SignDisplay.auto,
- Grouping useGrouping = Grouping.auto,
- String? numberingSystem,
- RoundingMode roundingMode = RoundingMode.halfExpand,
- TrailingZeroDisplay trailingZeroDisplay = TrailingZeroDisplay.auto,
- int minimumIntegerDigits = 1,
- Digits? digits,
Implementation
factory NumberFormatOptions.compact({
CompactDisplay compactDisplay = CompactDisplay.short,
//General options
FormatStyle style = const DecimalStyle(),
LocaleMatcher localeMatcher = LocaleMatcher.bestfit,
SignDisplay signDisplay = SignDisplay.auto,
Grouping useGrouping = Grouping.auto,
String? numberingSystem,
RoundingMode roundingMode = RoundingMode.halfExpand,
TrailingZeroDisplay trailingZeroDisplay = TrailingZeroDisplay.auto,
int minimumIntegerDigits = 1,
Digits? digits,
}) {
return NumberFormatOptions.custom(
style: style,
localeMatcher: localeMatcher,
signDisplay: signDisplay,
notation: CompactNotation(compactDisplay: compactDisplay),
useGrouping: useGrouping,
numberingSystem: numberingSystem,
roundingMode: roundingMode,
trailingZeroDisplay: trailingZeroDisplay,
minimumIntegerDigits: minimumIntegerDigits,
digits: digits,
);
}