Class MathUtil


  • public class MathUtil
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      MathUtil()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static int roundTowards​(double value, int target)
      Rounds value towards target to exact integer value.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MathUtil

        public MathUtil()
    • Method Detail

      • roundTowards

        public static int roundTowards​(double value,
                                       int target)
        Rounds value towards target to exact integer value.
        Parameters:
        value - the value to be rounded
        target - the target to be rounded towards
        Returns:
        the rounded value