Class RosettaNumber

java.lang.Object
java.lang.Number
com.rosetta.model.lib.RosettaNumber
All Implemented Interfaces:
Serializable, Comparable<RosettaNumber>

public class RosettaNumber extends Number implements Comparable<RosettaNumber>
An implementation of the IEEE754 decimal128 standard. Under the hood, this class uses BigDecimal. Also see MathContext.DECIMAL128. (Actually, *almost* an implementation of the decimal128 standard. See section "Relation to IEEE 754 Decimal Arithmetic" in the BigDecimal documentation for edge cases: https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/math/BigDecimal.html ) Note that this class circumvents problems caused by a per-instance precision, like in BigDecimal. E.g., for equality, see https://stackoverflow.com/q/6787142/3083982
See Also: