Java Double Number Round round(double value)

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

Description

round

License

Open Source License

Declaration

public static double round(double value) 

Method Source Code

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

public class Main {
    public static double round(double value) {
        final double NUMBER_OF_DIGITS = 1E5;
        return (double) Math.round(value * NUMBER_OF_DIGITS) / NUMBER_OF_DIGITS;
    }//from   w  ww .  ja  v a 2 s  . c  o  m
}

Related

  1. round(double value)
  2. round(double value)
  3. round(double value)
  4. round(double value)
  5. round(double value)
  6. round(double value, double decimalplaces)
  7. round(double value, double factor)
  8. round(double value, double increment)
  9. round(double value, double precision)