Decimal Mode
constructor(decimalPrecision: Long = 0, roundingMode: RoundingMode = RoundingMode.NONE, scale: Long = -1)
Parameters
decimal Precision
max number of digits allowed. Default 0 is unlimited precision.
rounding Mode
default RoundingMode.NONE is used with unlimited precision and no specified scale. Otherwise specify mode that is used for rounding when decimalPrecision is exceeded, or when scale is in use.
scale
is number of digits to the right of the decimal point. When this is specified, a RoundingMode that is not RoundingMode.NONE is also required. Scale cannot be greater than precision - 1. If left to default = null, no scale will be used. Rounding and decimalPrecision apply. Negative scale numbers are not supported. Using scale will increase the precision to required number of digits.