Java BigDecimal Subtract subtract2Abs(BigDecimal aValue1, BigDecimal aValue2)

Here you can find the source of subtract2Abs(BigDecimal aValue1, BigDecimal aValue2)

Description

subtract Abs

License

Open Source License

Declaration

public static BigDecimal subtract2Abs(BigDecimal aValue1, BigDecimal aValue2) 

Method Source Code


//package com.java2s;
import java.math.BigDecimal;

public class Main {

    public static BigDecimal subtract2Abs(BigDecimal aValue1, BigDecimal aValue2) {
        if (aValue1 == null || aValue2 == null)
            return null;

        return aValue1.subtract(aValue2).abs();
    }/*from   w w  w  .  j  a va 2s  .  c  o  m*/

    public static BigDecimal subtract(BigDecimal aValue1, BigDecimal aValue2) {
        if (aValue1 == null || aValue2 == null)
            return null;

        return aValue1.subtract(aValue2);
    }
}

Related

  1. subtract(BigDecimal v1, BigDecimal v2)
  2. subtract(final BigDecimal baseAmount, final BigDecimal amountToSubtract)
  3. subtract(final BigDecimal start, final BigDecimal... values)
  4. subtract(float a, BigDecimal b_bd)
  5. subtract(Vector a, Vector b)
  6. subtractPercent(BigDecimal price, double amount)
  7. subtractQtde(BigDecimal val1, BigDecimal val2)
  8. subtractVatAmount(BigDecimal percentage, BigDecimal amount)
  9. subUlp(BigDecimal x)