/// <reference path="./sigApi.Formula.d.ts" />

declare namespace SigApi {
    interface Unit {
        /**
         * Returns the name of a Unit
         * 
         * @returns {string} The name
         */
        getName(): string
        /**
         * @returns {number}
         */
        getUnitId(): number
        /**
         * Returns the maximal number of decimal digits
         * 
         * @returns {number|undefined} The maximal number of decimal digits (undefined if nothing is set)
         */
        getNumDecimalDigits(): number | undefined
        /**
         * Returns the maximal number of digits
         * 
         * @returns {number|undefined} The number of digits (undefined if nothing is set)
         */
        getNumDigits(): number | undefined
        /**
         * Returns a boolean which describes if the unit has leading zeros
         * 
         * @returns {boolean} true if the unit has leading zeros
         */
        hasLeadingZeros(): boolean
        /**
         * Returns a boolean which describes if the unit has a fixed decimal point
         * 
         * @returns {boolean} true if the unit has a fixed decimal point
         */
        hasFixedDecimalPoint(): boolean
        /**
         * Returns the Unittext of this unit
         * 
         * @returns {string} the unittext
         */
        getUnitText(): string
        /**
         * Returns if the unit has a formula
         * 
         * @returns {boolean} true if the unit has a formula
         */
        hasFormula(): boolean
        /**
         * Returns the formula
         * 
         * @returns {null|Formula} Returns the formula or null
         */
        getFormula(): Formula | null
    }
}
