List of usage examples for java.math BigDecimal subtract
public BigDecimal subtract(BigDecimal subtrahend)
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getNetAssetVar2() { try {// w w w.jav a2s . c om BigDecimal res = new BigDecimal(financialRatio.getNetAsset().doubleValue()); res = res.divide(financialRatioCompTwo.getNetAsset(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getReservesVar1() { try {/*from w ww .j av a2 s .co m*/ BigDecimal res = new BigDecimal(financialRatio.getReserves().doubleValue()); res = res.divide(financialRatioCompOne.getReserves(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getReservesVar2() { try {// ww w . j a v a 2 s . c om BigDecimal res = new BigDecimal(financialRatio.getReserves().doubleValue()); res = res.divide(financialRatioCompTwo.getReserves(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getExpensesVar1() { try {//from w w w . java2 s . c o m BigDecimal res = new BigDecimal(financialRatio.getExpenses().doubleValue()); res = res.divide(financialRatioCompOne.getExpenses(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getExpensesVar2() { try {//from w w w . ja v a 2 s . c om BigDecimal res = new BigDecimal(financialRatio.getExpenses().doubleValue()); res = res.divide(financialRatioCompTwo.getExpenses(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getCustomersVar1() { try {/*from ww w . j a v a2 s. c o m*/ BigDecimal res = new BigDecimal(financialRatio.getCustomers().doubleValue()); res = res.divide(financialRatioCompOne.getCustomers(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getCustomersVar2() { try {//from ww w . j ava2 s. c om BigDecimal res = new BigDecimal(financialRatio.getCustomers().doubleValue()); res = res.divide(financialRatioCompTwo.getCustomers(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getTotalAssetVar1() { try {//from ww w . j a va2s. com BigDecimal res = new BigDecimal(financialRatio.getTotalAsset().doubleValue()); res = res.divide(financialRatioCompOne.getTotalAsset(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getTotalAssetVar2() { try {/*from w w w. j av a 2s.co m*/ BigDecimal res = new BigDecimal(financialRatio.getTotalAsset().doubleValue()); res = res.divide(financialRatioCompTwo.getTotalAsset(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }
From source file:com.autentia.intra.bean.billing.FinancialRatioBean.java
public BigDecimal getTotalOurResourcesVar1() { try {//from w ww.j a v a 2 s .c o m BigDecimal res = new BigDecimal(financialRatio.getTotalOurResources().doubleValue()); res = res.divide(financialRatioCompOne.getReserves(), 4, RoundingMode.HALF_UP); res = res.subtract(new BigDecimal(1)); return res; } catch (Exception e) { return new BigDecimal(0); } }