Package mondrian.util

Class Format.BasicFormat

    • Field Detail

      • code

        final int code
    • Constructor Detail

      • BasicFormat

        BasicFormat()
      • BasicFormat

        BasicFormat​(int code)
    • Method Detail

      • getFormatType

        mondrian.util.Format.FormatType getFormatType()
      • isApplicableTo

        boolean isApplicableTo​(double n)
        Returns whether this format can handle a given value.

        Usually returns true; one notable exception is a format for negative numbers which causes the number to be underflow to zero and therefore be ineligible for the negative format.

        Parameters:
        n - value
        Returns:
        Whether this format is applicable for a given value
      • isApplicableTo

        boolean isApplicableTo​(long n)
        Returns whether this format can handle a given value.

        Usually returns true; one notable exception is a format for negative numbers which causes the number to be underflow to zero and therefore be ineligible for the negative format.

        Parameters:
        n - value
        Returns:
        Whether this format is applicable for a given value