Code example for BigDecimal

Methods: compareTo

0
        } 
        catch (Exception e2)
        { 
          if (c instanceof Number && comparable instanceof Number)
          { 
            final BigDecimal bd1 = new BigDecimal(String.valueOf(c));
            final BigDecimal bd2 = new BigDecimal(String.valueOf(comparable));
            result = bd1.compareTo(bd2);
          } 
          else 
          { 
            // not comparable .. 
            return Boolean.FALSE;
          } 
        } 
      } 
 
      final String method = getCompareMethod();
      if (AbstractCompareExpression.EQUAL.equals(method))
      { 
Contextual code suggestions in your IDE  Get Codota for Java