ScientificValue

A Value in a given ScientificUnit

Type Parameters

Quantity

the type of PhysicalQuantity of the unit

Unit

the type of ScientificUnit this value represents

Inheritors

Properties

Link copied to clipboard

A Decimal representation of value

Link copied to clipboard
abstract val unit: Unit

The Unit component

Link copied to clipboard
abstract val value: Number

The value component

Functions

Link copied to clipboard
Link copied to clipboard
open operator override fun compareTo(other: ScientificValue<Quantity, *>): Int
Link copied to clipboard

Converts a ScientificValue into another ScientificValue with a ScientificUnit of the same PhysicalQuantity

Link copied to clipboard

Creates a DefaultScientificValue equal to the ScientificValue.value increased by value

Creates a DefaultScientificArray in Unit by adding a ScientificArray to this ScientificValue This will convert the values right into Unit

Creates a Value equal to the ScientificValue.value increased by value

Link copied to clipboard

Splits a ScientificValue of ValueUnit into a DefaultScientificValue of ValueUnit and DefaultScientificValue of RightUnit so that left and right together are equal to the original value. Splitting happens by rounding the ValueUnit down to scale and returning it and the remainder converted to RightUnit.

Splits a ScientificValue of ValueUnit into a DefaultScientificValue of LeftUnit and DefaultScientificValue of RightUnit so that left and right together are equal to the original value. Splitting happens by converting the ValueUnit to LeftUnit and then rounding down to scale and returning it and the remainder converted to RightUnit.

Splits a ScientificValue of ValueUnit into a LeftValue and RightValue so that left and right together are equal to the original value. Splitting happens by rounding the ValueUnit down to scale and returning it and the remainder converted to RightUnit.

Splits a ScientificValue of ValueUnit into a LeftValue and RightValue so that left and right together are equal to the original value. Splitting happens by converting the ValueUnit to LeftUnit and then rounding down to scale and returning it and the remainder converted to RightUnit.

Link copied to clipboard

Breaks up a ScientificValue of Quantity into its components in UnitOne, UnitTwo and executes the given action with these components. A value is broken up into its components by converting the value to to UnitOne and splitting into UnitTwo using scale.

Breaks up a ScientificValue of Quantity into its components in UnitOne, UnitTwo, UnitThree and executes the given action with these components. A value is broken up into its components by converting the value to to UnitOne and splitting into UnitTwo using scale, then splitting the remainder into UnitThree.

Breaks up a ScientificValue of Quantity into its components in UnitOne, UnitTwo, UnitThree, UnitFour and executes the given action with these components. A value is broken up into its components by converting the value to to UnitOne and splitting into UnitTwo using scale, then splitting the remainder into UnitThree and so on.

Breaks up a ScientificValue of Quantity into its components in UnitOne, UnitTwo, UnitThree, UnitFour, UnitFive and executes the given action with these components. A value is broken up into its components by converting the value to to UnitOne and splitting into UnitTwo using scale, then splitting the remainder into UnitThree and so on.

Link copied to clipboard
fun ScientificValue<*, *>.toString(formatter: ScientificValueFormatter = CommonScientificValueFormatter.default): String

Gets the String representation of a ScientificValue using a ScientificValueFormatter