Home
last modified time | relevance | path

Searched refs:maxSig (Results 1 – 17 of 17) sorted by relevance

/external/icu/android_icu4j/src/main/java/android/icu/number/
DPrecision.java460 static Precision constructSignificant(int minSig, int maxSig) { in constructSignificant() argument
461 if (minSig == 2 && maxSig == 2) { in constructSignificant()
463 } else if (minSig == 3 && maxSig == 3) { in constructSignificant()
465 } else if (minSig == 2 && maxSig == 3) { in constructSignificant()
468 return new SignificantRounderImpl(minSig, maxSig); in constructSignificant()
472 static Precision constructFractionSignificant(FractionPrecision base_, int minSig, int maxSig) { in constructFractionSignificant() argument
478 return new FracSigRounderImpl(base.minFrac, base.maxFrac, minSig, maxSig); in constructFractionSignificant()
623 final int maxSig; field in Precision.SignificantRounderImpl
625 public SignificantRounderImpl(int minSig, int maxSig) { in SignificantRounderImpl() argument
627 this.maxSig = maxSig; in SignificantRounderImpl()
[all …]
DNumberPropertyMapper.java142 int maxSig = properties.getMaximumSignificantDigits(); in oldToNew() local
146 boolean explicitMinMaxSig = minSig != -1 || maxSig != -1; in oldToNew()
187 maxSig = maxSig < 0 ? RoundingUtils.MAX_INT_FRAC_SIG in oldToNew()
188 : maxSig < minSig ? minSig in oldToNew()
189 … : maxSig > RoundingUtils.MAX_INT_FRAC_SIG ? RoundingUtils.MAX_INT_FRAC_SIG in oldToNew()
190 : maxSig; in oldToNew()
191 rounding = Precision.constructSignificant(minSig, maxSig); in oldToNew()
336 int maxSig_ = maxSig; in oldToNew()
347 maxSig_ = ((SignificantRounderImpl) rounding_).maxSig; in oldToNew()
DNumberSkeletonImpl.java1040 int maxSig; in parseDigitsStem() local
1050 maxSig = -1; in parseDigitsStem()
1053 maxSig = minSig; in parseDigitsStem()
1056 maxSig++; in parseDigitsStem()
1063 maxSig = minSig; in parseDigitsStem()
1069 if (maxSig == -1) { in parseDigitsStem()
1072 macros.precision = Precision.minMaxSignificantDigits(minSig, maxSig); in parseDigitsStem()
1076 private static void generateDigitsStem(int minSig, int maxSig, StringBuilder sb) { in generateDigitsStem() argument
1078 if (maxSig == -1) { in generateDigitsStem()
1081 appendMultiple(sb, '#', maxSig - minSig); in generateDigitsStem()
[all …]
/external/icu/icu4j/main/classes/core/src/com/ibm/icu/number/
DPrecision.java472 static Precision constructSignificant(int minSig, int maxSig) { in constructSignificant() argument
473 if (minSig == 2 && maxSig == 2) { in constructSignificant()
475 } else if (minSig == 3 && maxSig == 3) { in constructSignificant()
477 } else if (minSig == 2 && maxSig == 3) { in constructSignificant()
480 return new SignificantRounderImpl(minSig, maxSig); in constructSignificant()
484 static Precision constructFractionSignificant(FractionPrecision base_, int minSig, int maxSig) { in constructFractionSignificant() argument
490 return new FracSigRounderImpl(base.minFrac, base.maxFrac, minSig, maxSig); in constructFractionSignificant()
635 final int maxSig; field in Precision.SignificantRounderImpl
637 public SignificantRounderImpl(int minSig, int maxSig) { in SignificantRounderImpl() argument
639 this.maxSig = maxSig; in SignificantRounderImpl()
[all …]
DNumberPropertyMapper.java141 int maxSig = properties.getMaximumSignificantDigits(); in oldToNew() local
145 boolean explicitMinMaxSig = minSig != -1 || maxSig != -1; in oldToNew()
186 maxSig = maxSig < 0 ? RoundingUtils.MAX_INT_FRAC_SIG in oldToNew()
187 : maxSig < minSig ? minSig in oldToNew()
188 … : maxSig > RoundingUtils.MAX_INT_FRAC_SIG ? RoundingUtils.MAX_INT_FRAC_SIG in oldToNew()
189 : maxSig; in oldToNew()
190 rounding = Precision.constructSignificant(minSig, maxSig); in oldToNew()
335 int maxSig_ = maxSig; in oldToNew()
346 maxSig_ = ((SignificantRounderImpl) rounding_).maxSig; in oldToNew()
DNumberSkeletonImpl.java1039 int maxSig; in parseDigitsStem() local
1049 maxSig = -1; in parseDigitsStem()
1052 maxSig = minSig; in parseDigitsStem()
1055 maxSig++; in parseDigitsStem()
1062 maxSig = minSig; in parseDigitsStem()
1068 if (maxSig == -1) { in parseDigitsStem()
1071 macros.precision = Precision.minMaxSignificantDigits(minSig, maxSig); in parseDigitsStem()
1075 private static void generateDigitsStem(int minSig, int maxSig, StringBuilder sb) { in generateDigitsStem() argument
1077 if (maxSig == -1) { in generateDigitsStem()
1080 appendMultiple(sb, '#', maxSig - minSig); in generateDigitsStem()
[all …]
/external/icu/icu4c/source/i18n/
Dnumber_mapper.cpp103 int32_t maxSig = properties.maximumSignificantDigits; in oldToNew() local
107 bool explicitMinMaxSig = minSig != -1 || maxSig != -1; in oldToNew()
147 maxSig = maxSig < 0 ? kMaxIntFracSig : maxSig < minSig ? minSig : maxSig > kMaxIntFracSig in oldToNew()
148 ? kMaxIntFracSig : maxSig; in oldToNew()
149 precision = Precision::constructSignificant(minSig, maxSig); in oldToNew()
293 int maxSig_ = maxSig; in oldToNew()
Dnumber_rounding.cpp32 int32_t getRoundingMagnitudeSignificant(const DecimalQuantity &value, int maxSig) { in getRoundingMagnitudeSignificant() argument
33 if (maxSig == -1) { in getRoundingMagnitudeSignificant()
37 return magnitude - maxSig + 1; in getRoundingMagnitudeSignificant()
234 Precision Precision::constructSignificant(int32_t minSig, int32_t maxSig) { in constructSignificant() argument
239 settings.fMaxSig = static_cast<digits_t>(maxSig); in constructSignificant()
246 …sion::constructFractionSignificant(const FractionPrecision &base, int32_t minSig, int32_t maxSig) { in constructFractionSignificant() argument
249 settings.fMaxSig = static_cast<digits_t>(maxSig); in constructFractionSignificant()
Dnumber_skeletons.cpp1022 int maxSig; in parseDigitsStem() local
1032 maxSig = -1; in parseDigitsStem()
1035 maxSig = minSig; in parseDigitsStem()
1038 maxSig++; in parseDigitsStem()
1045 maxSig = minSig; in parseDigitsStem()
1053 if (maxSig == -1) { in parseDigitsStem()
1056 macros.precision = Precision::minMaxSignificantDigits(minSig, maxSig); in parseDigitsStem()
1061 blueprint_helpers::generateDigitsStem(int32_t minSig, int32_t maxSig, UnicodeString& sb, UErrorCode… in generateDigitsStem() argument
1063 if (maxSig == -1) { in generateDigitsStem()
1066 appendMultiple(sb, u'#', maxSig - minSig); in generateDigitsStem()
[all …]
Dnumber_patternstring.cpp663 int maxSig = uprv_min(properties.maximumSignificantDigits, dosMax); in propertiesToPatternString() local
709 if (maxSig != uprv_min(dosMax, -1)) { in propertiesToPatternString()
714 while (digitsString.length() < maxSig) { in propertiesToPatternString()
Dnumber_skeletons.h234 void generateDigitsStem(int32_t minSig, int32_t maxSig, UnicodeString& sb, UErrorCode& status);
Ddecimfmt.cpp1072 int32_t maxSig = useSignificantDigits ? 6 : -1; in setSignificantDigitsUsed() local
1074 fields->properties->maximumSignificantDigits = maxSig; in setSignificantDigitsUsed()
/external/icu/icu4j/main/classes/core/src/com/ibm/icu/impl/number/
DPatternStringUtils.java45 int maxSig = Math.min(properties.getMaximumSignificantDigits(), dosMax); in propertiesToPatternString() local
92 if (maxSig != Math.min(dosMax, -1)) { in propertiesToPatternString()
97 while (digitsString.length() < maxSig) { in propertiesToPatternString()
/external/icu/android_icu4j/src/main/java/android/icu/impl/number/
DPatternStringUtils.java47 int maxSig = Math.min(properties.getMaximumSignificantDigits(), dosMax); in propertiesToPatternString() local
94 if (maxSig != Math.min(dosMax, -1)) { in propertiesToPatternString()
99 while (digitsString.length() < maxSig) { in propertiesToPatternString()
/external/icu/icu4c/source/i18n/unicode/
Dnumberformatter.h782 static Precision constructSignificant(int32_t minSig, int32_t maxSig);
785 constructFractionSignificant(const FractionPrecision &base, int32_t minSig, int32_t maxSig);
/external/icu/android_icu4j/src/main/java/android/icu/text/
DDecimalFormat.java1481 int maxSig = useSignificantDigits ? 6 : -1; in setSignificantDigitsUsed() local
1483 properties.setMaximumSignificantDigits(maxSig); in setSignificantDigitsUsed()
/external/icu/icu4j/main/classes/core/src/com/ibm/icu/text/
DDecimalFormat.java1576 int maxSig = useSignificantDigits ? 6 : -1; in setSignificantDigitsUsed() local
1578 properties.setMaximumSignificantDigits(maxSig); in setSignificantDigitsUsed()