Java BigDecimal Round round(BigDecimal value)

Here you can find the source of round(BigDecimal value)

Description

round

License

Open Source License

Declaration

public static BigDecimal round(BigDecimal value) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.math.BigDecimal;

public class Main {
    public static BigDecimal round(BigDecimal value) {
        return value.setScale(2, BigDecimal.ROUND_HALF_UP);
    }// www. ja v a 2s  .c o  m
}

Related

  1. round(BigDecimal initData, int scale)
  2. round(BigDecimal money, int scale)
  3. round(BigDecimal num, int scale)
  4. round(BigDecimal number)
  5. round(BigDecimal v, int scale, int roundingMode)
  6. round(BigDecimal value)
  7. round(BigDecimal value, BigDecimal increment, RoundingMode roundingMode)
  8. round(BigDecimal value, int accuracy)
  9. round(BigDecimal value, int places)