convertValue
fun <Quantity : PhysicalQuantity, Unit : ScientificUnit<Quantity>, TargetUnit : ScientificUnit<Quantity>> ScientificValue<Quantity, Unit>.convertValue(target: TargetUnit): Decimal
Converts ScientificValue.value into the equivalent Decimal in TargetUnit
Return
the Decimal value in TargetUnit equivalent to ScientificValue.value
Parameters
Quantity
the type of PhysicalQuantity of the Unit and TargetUnit
Unit
the type of ScientificUnit of the ScientificValue
TargetUnit
the type of ScientificUnit to convert to
target
the TargetUnit to convert to
fun <Quantity : PhysicalQuantity, Unit : ScientificUnit<Quantity>, TargetUnit : ScientificUnit<Quantity>> ScientificValue<Quantity, Unit>.convertValue(target: TargetUnit, round: Int, roundingMode: RoundingMode = RoundingMode.RoundHalfEven): Decimal
Converts ScientificValue.value into the equivalent Decimal in TargetUnit
Return
the Decimal value in TargetUnit equivalent to ScientificValue.value
Parameters
Quantity
the type of PhysicalQuantity of the Unit and TargetUnit
Unit
the type of ScientificUnit of the ScientificValue
TargetUnit
the type of ScientificUnit to convert to
target
the TargetUnit to convert to
round
The number of digits a rounded value should have after its decimal point
roundingMode
The RoundingMode to apply when scaling