Here you can find the source of lessThanZero(BigDecimal decimal)
Parameter | Description |
---|---|
decimal | a parameter |
public static final boolean lessThanZero(BigDecimal decimal)
//package com.java2s; import java.math.BigDecimal; public class Main { /**//w w w. j a va 2 s . co m * Is de waarde kleiner dan 0, null is groter dan 0. * * @param decimal * @return true als de waarde kleiner dan 0 is, anders false */ public static final boolean lessThanZero(BigDecimal decimal) { if (decimal == null) return false; return decimal.compareTo(BigDecimal.ZERO) < 0; } }