numberToDecimal

fun numberToDecimal(number: Number): BigDecimal

Non-extension equivalent of Number.toDecimal, for callers that cannot use a with receiver scope.

Throws

if number's String representation is not a valid decimal literal