mirror of
https://github.com/unicode-org/icu.git
synced 2025-04-16 10:17:23 +00:00
ICU-6354 Set default rounding increment, Java implementation
X-SVN-Rev: 25242
This commit is contained in:
parent
de7d1f06de
commit
e386fb0a43
1 changed files with 6 additions and 1 deletions
|
@ -1,7 +1,7 @@
|
|||
//##header J2SE15
|
||||
/*
|
||||
*******************************************************************************
|
||||
* Copyright (C) 1996-2008, International Business Machines Corporation and *
|
||||
* Copyright (C) 1996-2009, International Business Machines Corporation and *
|
||||
* others. All Rights Reserved. *
|
||||
*******************************************************************************
|
||||
*/
|
||||
|
@ -3211,7 +3211,12 @@ public class DecimalFormat extends NumberFormat {
|
|||
throw new IllegalArgumentException("Invalid rounding mode: "
|
||||
+ roundingMode);
|
||||
}
|
||||
|
||||
this.roundingMode = roundingMode;
|
||||
|
||||
if (getRoundingIncrement() == null) {
|
||||
setRoundingIncrement(Math.pow(10.0,(double)-getMaximumFractionDigits()));
|
||||
}
|
||||
}
|
||||
|
||||
// [NEW]
|
||||
|
|
Loading…
Add table
Reference in a new issue