I have the following code in Java;
BigDecimal price; // assigned elsewhere if (price.compareTo(new BigDecimal(\"0.00\")) == 0) { return true; } <
BigDecimal price; // assigned elsewhere if (price.compareTo(new BigDecimal(\"0.00\")) == 0) { return true; }
There is a constant that you can check against:
someBigDecimal.compareTo(BigDecimal.ZERO) == 0