round

infix fun BigDecimal.round(scale: Int): BigDecimal(source)

Rounds the BigDecimal to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

BigDecimal

Return

The rounded value.

Parameters

scale

The scale to round a value.


infix fun BigDecimal.round(rounding: Rounding): BigDecimal(source)

Rounds the BigDecimal using the given Rounding.

Receiver

BigDecimal

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.


fun () -> BigDecimal.round(scale: Int): BigDecimal(source)

Rounds the BigDecimal to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

(() -> BigDecimal)

Return

The rounded value.

Parameters

scale

The scale to round a value.


fun () -> BigDecimal.round(rounding: Rounding): BigDecimal(source)

Rounds the BigDecimal using the given Rounding.

Receiver

(() -> BigDecimal)

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.


infix fun Double.round(scale: Int): Double(source)

Rounds the double value to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

Double

Return

The rounded value.

Parameters

scale

The scale to round a value.


infix fun Double.round(rounding: Rounding): Double(source)

Rounds the double value using the given Rounding.

Receiver

Double

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.


fun () -> Double.round(scale: Int): Double(source)

Rounds the double value to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

(() -> Double)

Return

The rounded value.

Parameters

scale

The scale to round a value.


fun () -> Double.round(rounding: Rounding): Double(source)

Rounds the double value using the given Rounding.

Receiver

(() -> Double)

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.


infix fun Float.round(scale: Int): Float(source)

Rounds the float value to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

Float

Return

The rounded value.

Parameters

scale

The scale to round a value.


infix fun Float.round(rounding: Rounding): Float(source)

Rounds the float value using the given Rounding.

Receiver

Float

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.


fun () -> Float.round(scale: Int): Float(source)

Rounds the double value to a given precision scale using java.math.RoundingMode.HALF_EVEN rounding mode.

Receiver

(() -> Float)

Return

The rounded value.

Parameters

scale

The scale to round a value.


fun () -> Float.round(rounding: Rounding): Float(source)

Rounds the double value using the given Rounding.

Receiver

(() -> Float)

Return

The rounded value.

Parameters

rounding

The Rounding strategy to round the value.