com.ihr.xbrl.om.instance

## Class XBRLFractionValue

- java.lang.Object
- - com.ihr.xbrl.om.instance.XBRLFractionValue

- All Implemented Interfaces:
    XBRLNumber

      public class XBRLFractionValue
      extends java.lang.Object
      implements XBRLNumber

  The Class XBRLFractionValue.
  Author:
    Ignacio

- - ### Field Summary

    - ### Fields inherited from interface com.ihr.xbrl.om.instance.XBRLNumber

      `DECIMALS, INF, PRECISION`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `XBRLFractionValue(XBRLFactNumeric fact, java.lang.Number numerator, java.lang.Number denominator)` Instantiates a new XBRL fraction value.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `XBRLFractionValue` | `clone()` Clone.
    `boolean` | `eq(XBRLNumber vb)` Eq.
    `java.lang.String` | `getDecimals()` Convert precision value into decimals value if needed and returns the decimals value It is returned as a string because "INF" is a valid value.
    `java.lang.Number` | `getDenominator()` Gets the denominator.
    `XBRLFactNumeric` | `getFact()` Access to the XBRLFactNumeric that is the container of this XBRLNumericValue.
    `double` | `getFractionValue()` Gets the fraction value.
    `java.lang.String` | `getFriendlyName(int flags, LabelsProvider lp)` Gets the friendly name.
    `int` | `getInferredPrecision()` Gets the inferred precision for this numeric value.
    `java.lang.Number` | `getNumerator()` Gets the numerator.
    `boolean` | `isBlank()` true if this XBRLNumericValue has no value assigned .
    `XBRLNumber` | `multiply(double weight)` Multiply.
    `boolean` | `ne(XBRLNumber other)` Ne.
    `XBRLNumber` | `plus(XBRLNumber multiply)` Plus.
    `void` | `setDenominator(java.lang.Number denominator)` Sets the denominator.
    `void` | `setFact(XBRLFactNumeric factNumeric)` Sets the fact.
    `void` | `setNumerator(java.lang.Number numerator)` Sets the numerator.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface com.ihr.xbrl.om.instance.XBRLNumber

      `hashCode`

- - ### Constructor Detail

    - #### XBRLFractionValue

          public XBRLFractionValue(XBRLFactNumeric fact,
                           java.lang.Number numerator,
                           java.lang.Number denominator)

      Instantiates a new XBRL fraction value.
      Parameters:
        `fact` - the fact
        `numerator` - the numerator
        `denominator` - the denominator

  - ### Method Detail

    - #### getNumerator

          public java.lang.Number getNumerator()

      Gets the numerator.
      Returns:
        the numerator

    - #### getDenominator

          public java.lang.Number getDenominator()

      Gets the denominator.
      Returns:
        the denominator

    - #### setNumerator

          public void setNumerator(java.lang.Number numerator)

      Sets the numerator.
      Parameters:
        `numerator` - the numerator to set

    - #### setDenominator

          public void setDenominator(java.lang.Number denominator)

      Sets the denominator.
      Parameters:
        `denominator` - the denominator to set

    - #### clone

          public XBRLFractionValue clone()

      Description copied from interface: `XBRLNumber`
      Clone.
      Specified by:
        `clone` in interface `XBRLNumber`
      Overrides:
        `clone` in class `java.lang.Object`
      Returns:
        the XBRL number

    - #### getDecimals

          public java.lang.String getDecimals()

      Description copied from interface: `XBRLNumber`
      Convert precision value into decimals value if needed and returns the decimals value It is returned as a string because "INF" is a valid value.
      Specified by:
        `getDecimals` in interface `XBRLNumber`
      Returns:
        String

    - #### getFact

          public XBRLFactNumeric getFact()

      Description copied from interface: `XBRLNumber`
      Access to the XBRLFactNumeric that is the container of this XBRLNumericValue.

      It may be null

      Specified by:
        `getFact` in interface `XBRLNumber`
      Returns:
        XBRLFactNumeric or null

    - #### getInferredPrecision

          public int getInferredPrecision()

      Description copied from interface: `XBRLNumber`
      Gets the inferred precision for this numeric value.
      Specified by:
        `getInferredPrecision` in interface `XBRLNumber`
      Returns:
        integer

    - #### isBlank

          public boolean isBlank()

      Description copied from interface: `XBRLNumber`
      true if this XBRLNumericValue has no value assigned .
      Specified by:
        `isBlank` in interface `XBRLNumber`
      Returns:
        the bBlank

    - #### setFact

          public void setFact(XBRLFactNumeric factNumeric)

      Description copied from interface: `XBRLNumber`
      Sets the fact.
      Specified by:
        `setFact` in interface `XBRLNumber`
      Parameters:
        `factNumeric` - the new fact

    - #### eq

          public boolean eq(XBRLNumber vb)

      Description copied from interface: `XBRLNumber`
      Eq.
      Specified by:
        `eq` in interface `XBRLNumber`
      Parameters:
        `vb` - the vb
      Returns:
        true, if successful

    - #### multiply

          public XBRLNumber multiply(double weight)

      Description copied from interface: `XBRLNumber`
      Multiply.
      Specified by:
        `multiply` in interface `XBRLNumber`
      Parameters:
        `weight` - the weight
      Returns:
        the XBRL number

    - #### ne

          public boolean ne(XBRLNumber other)

      Description copied from interface: `XBRLNumber`
      Ne.
      Specified by:
        `ne` in interface `XBRLNumber`
      Parameters:
        `other` - the sum item
      Returns:
        true, if successful

    - #### plus

          public XBRLNumber plus(XBRLNumber multiply)

      Description copied from interface: `XBRLNumber`
      Plus.
      Specified by:
        `plus` in interface `XBRLNumber`
      Parameters:
        `multiply` - the multiply
      Returns:
        the XBRL number

    - #### getFractionValue

          public double getFractionValue()

      Gets the fraction value.
      Returns:
        the fraction value

    - #### getFriendlyName

          public java.lang.String getFriendlyName(int flags,
                                         LabelsProvider lp)

      Description copied from interface: `XBRLNumber`
      Gets the friendly name.
      Specified by:
        `getFriendlyName` in interface `XBRLNumber`
      Parameters:
        `flags` - XMLFragment.HIDE_COMMON_ACCURACY can be used to remove suffixes
        `lp` - (can be null, it is not used)
      Returns:
        the friendly name