/** @packageDocumentation * @module Quantity */ import { FormatterSpec } from "./FormatterSpec"; /** A helper class that contains methods used to format quantity values based on a format that are defined via the Format class. * @beta */ export declare class Formatter { private static FPV_MINTHRESHOLD; private static isNegligible; /** Return floating point value rounded by specific rounding factor. * @param value Value to be rounded. * @param roundTo Rounding factor. */ private static roundDouble; /** Generate a formatted text string integer value insert 1000 separators if appropriate. * @param wholePart Integer value to be formatted. */ private static integerPartToText; /** Trim trailing "0" from the text that represent the fractional part of a floating point value. * @param strVal The value string. */ private static trimTrailingZeroes; /** Format a quantity value into a composite format such as ft-in or deg-min-sec. * @param compositeValue The value for this part of the composite * @param isLastPart If false the composite value should be a whole value, if true then the value should be formatted as a floating point value. * @param label Label for this part of the composite. This will be either the default unit label or a custom label specified the format specification. */ private static formatCompositePart; /** Format a quantity value into a composite format such as ft-in or deg-min-sec. * @param magnitude quantity value * @param fromUnit quantity unit */ private static formatComposite; /** Format a quantity value into a single text string. Imitate how formatting done by server method NumericFormatSpec::FormatDouble. * @param magnitude quantity value */ private static formatMagnitude; private static countAndPad; /** Helper function to apply sign formatting based on showSignOption * @param isNegative whether the value should be treated as negative * @param showSignOption the sign display option * @param formatType the format type (to handle bearing/azimuth exceptions) * @returns object containing prefix and suffix strings */ private static applySignFormatting; /** Format a quantity value into a single text string based on the current format specification of this class. * @param magnitude defines the value to spec.format. * @param spec A FormatterSpec object the defines specification for the magnitude and unit conversions for the formatter. */ static formatQuantity(magnitude: number, spec: FormatterSpec): string; private static processBearingAndAzimuth; private static normalizeAngle; private static getRevolution; private static formatRatioPart; /** Format a ratio quantity value (separate from composite formatting) */ private static formatRatioQuantity; private static formatRatio; } //# sourceMappingURL=Formatter.d.ts.map