Class Math2


  • public class Math2
    extends java.lang.Object
    Contains functions we wish were in java.lang.Math
    • Constructor Summary

      Constructors 
      Constructor Description
      Math2()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static double clamp​(double val, double min, double max)  
      static float clamp​(float val, float min, float max)  
      static int clamp​(int val, int min, int max)  
      static long clamp​(long val, long min, long max)  
      • Methods inherited from class java.lang.Object

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

      • Math2

        public Math2()
    • Method Detail

      • clamp

        public static int clamp​(int val,
                                int min,
                                int max)
      • clamp

        public static long clamp​(long val,
                                 long min,
                                 long max)
      • clamp

        public static float clamp​(float val,
                                  float min,
                                  float max)
      • clamp

        public static double clamp​(double val,
                                   double min,
                                   double max)