ilog.rules.dvs.common.descriptors

Class IlrComparisonPrecisionDescriptor

  • java.lang.Object
    • ilog.rules.dvs.common.descriptors.IlrComparisonPrecisionDescriptor
  • All Implemented Interfaces:
    java.io.Serializable


    public class IlrComparisonPrecisionDescriptor
    extends java.lang.Object
    implements java.io.Serializable
    Descriptor for the precision used when making assertions in tests.
    Since:
    7.0
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static int USE_ALL_DIGITS
      Compares all digits to the right of the decimal point.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      boolean equals(java.lang.Object obj) 
      int getDecimalPrecision()
      Returns the precision used for double comparison.
      int hashCode() 
      void setDecimalPrecision(int theDecimalPrecision)
      Sets the precision used for double comparison.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • USE_ALL_DIGITS

        public static final int USE_ALL_DIGITS
        Compares all digits to the right of the decimal point.
        See Also:
        Constant Field Values
    • Constructor Detail

      • IlrComparisonPrecisionDescriptor

        public IlrComparisonPrecisionDescriptor()
        Creates a new IlrComparisonPrecisionDescriptor object. The new instance has the following default value:
    • Method Detail

      • getDecimalPrecision

        public int getDecimalPrecision()
        Returns the precision used for double comparison.
        Returns:
        The number of digits to the right of the decimal point taken into account when comparing decimal numbers.
        See Also:
        setDecimalPrecision(int)
      • setDecimalPrecision

        public void setDecimalPrecision(int theDecimalPrecision)
        Sets the precision used for double comparison.
        Parameters:
        theDecimalPrecision - The number of digits to the right of the decimal point to take into account when comparing decimal numbers. Set to USE_ALL_DIGITS so all digits to the right of the decimal point are taken into account.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
        See Also:
        Object.hashCode()
      • equals

        public boolean equals(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
        See Also:
        Object.equals(Object)

© Copyright IBM Corp. 1987, 2017