Class ScientificNumberFormat

java.lang.Object
java.text.Format
java.text.NumberFormat
com.inductiveautomation.ignition.common.util.ScientificNumberFormat
All Implemented Interfaces:
Serializable, Cloneable

public class ScientificNumberFormat extends NumberFormat
A number format that will switch between a "small" and "large" format depending on the magnitude of the value. If the magnitude of the to-be-formatted value is below a settable threshold, then the small format will be used. Otherwise, and if the value is exactly equal to 0.0, the large format will be used.
See Also:
  • Constructor Details

    • ScientificNumberFormat

      public ScientificNumberFormat()
      Creates a Scientific number format with 10 significant digits and a threshold of 0.0001
    • ScientificNumberFormat

      public ScientificNumberFormat(int significantDigits, double threshold)
      Creates a scientific number format with any number of significant digits and a custom threshold
    • ScientificNumberFormat

      public ScientificNumberFormat(String largeFormat, String smallFormat, double threshold)
      Creates a scientific number format with custom large and small formats
  • Method Details