Java Utililty Methods BigDecimal Max

List of utility methods to do BigDecimal Max

Description

The list of methods to do BigDecimal Max are organized into topic(s).

Method

BigDecimalmaxUsingFirstSignum(final BigDecimal... values)
max Using First Signum
BigDecimal max = BigDecimal.ZERO;
boolean signumDetected = false;
BigDecimal signum = BigDecimal.ONE;
for (BigDecimal value : values) {
    if (value != null && value.compareTo(BigDecimal.ZERO) != 0) {
        if (!signumDetected) {
            signum = BigDecimal.valueOf(value.signum() == -1 ? -1 : 1);
            signumDetected = true;
...
booleanmaxValue(BigDecimal origen, BigDecimal montoMaximo)
max Value
if (origen == null)
    return false;
return origen.compareTo(montoMaximo) > 0;
BigDecimalmaxValue(BigDecimal[] bigDecimalNumbers)
max Value
return bigDecimalNumbers[bigDecimalNumbers.length - 1];