Uses of Class
java.math.RoundingMode
-
Packages that use RoundingMode 软件包 描述 java.math 提供执行任意精度整数运算(BigInteger)和任意精度十进制运算(BigDecimal)的类。java.text 提供用于以独立于自然语言的方式处理文本,日期,数字和消息的类和接口。 -
-
Uses of RoundingMode in java.math
Methods in java.math that return RoundingMode Modifier and Type 方法 描述 RoundingModeMathContext. getRoundingMode()返回roundingMode设置。static RoundingModeRoundingMode. valueOf(int rm)返回对应于RoundingMode中的遗留整数舍入模式常量的RoundingMode对象 。static RoundingModeRoundingMode. valueOf(String name)以指定的名称返回此类型的枚举常量。static RoundingMode[]RoundingMode. values()按照它们声明的顺序返回一个包含此枚举类型常量的数组。Methods in java.math with parameters of type RoundingMode Modifier and Type 方法 描述 BigDecimalBigDecimal. divide(BigDecimal divisor, int scale, RoundingMode roundingMode)返回BigDecimal,其值是(this / divisor),其标度为指定。BigDecimalBigDecimal. divide(BigDecimal divisor, RoundingMode roundingMode)返回BigDecimal,其值是(this / divisor),其标为this.scale()。BigDecimalBigDecimal. setScale(int newScale, RoundingMode roundingMode)返回一个BigDecimal其缩放比例是指定值,其缩放值通过将该BigDecimal的非标度值乘以10的适当功率来确定,以维持其整体值。Constructors in java.math with parameters of type RoundingMode Constructor 描述 MathContext(int setPrecision, RoundingMode setRoundingMode)构造一个新的MathContext具有指定的精度和舍入模式。 -
Uses of RoundingMode in java.text
Methods in java.text that return RoundingMode Modifier and Type 方法 描述 RoundingModeDecimalFormat. getRoundingMode()获取此DecimalFormat中使用的RoundingMode。RoundingModeNumberFormat. getRoundingMode()获取此NumberFormat中使用的RoundingMode。Methods in java.text with parameters of type RoundingMode Modifier and Type 方法 描述 voidDecimalFormat. setRoundingMode(RoundingMode roundingMode)设置此DecimalFormat中使用的RoundingMode。voidNumberFormat. setRoundingMode(RoundingMode roundingMode)设置此NumberFormat中使用的RoundingMode。
-