NoRounding

Strategy that does not round a value.

Properties

Link copied to clipboard
open val mode: RoundingMode

The rounding mode used to round the decimal value.

Link copied to clipboard
open val precision: Int

The precision to round the value (i.e., number of significant figures to use).

Functions

Link copied to clipboard
open operator override fun compareTo(other: Rounding): Int
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun round(value: BigDecimal): BigDecimal
open override fun round(value: Double): Double
open override fun round(value: Float): Float

Rounds the given value.

fun round(block: () -> BigDecimal): BigDecimal
fun round(block: () -> Double): Double
fun round(block: () -> Float): Float

Rounds the value returned by the function block.

Link copied to clipboard
open override fun toString(): String
Link copied to clipboard
open infix override fun with(precision: Int): Rounding

Returns a new Rounding with the given precision, keeping the current rounding mode.