ERROR - java.lang.ArithmeticException - Possible Causes of ArithmeticException

Exception Thrown By:Cause
ClassMethod
Duration public static Duration
ofHours(long hours)
if the input
hours exceeds the capacity of Duration.
Duration public static Duration
ofMinutes(long minutes)
if the input
minutes exceeds the capacity of Duration.
Math public static int
incrementExact(int a)
if the
result overflows an int
Math public static long
incrementExact(long a)
if the
result overflows a long
Math public static int
decrementExact(int a)
if the
result overflows an int
Math public static long
decrementExact(long a)
if the
result overflows a long
Math public static int
negateExact(int a)
if the
result overflows an int
Math public static long
negateExact(long a)
if the
result overflows a long
Math public static int
toIntExact(long value)
if the
argument overflows an int
NumberFormat public final String
format(double number)
if rounding is needed with
rounding mode being set to RoundingMode
NumberFormat public final String
format(long number)
if rounding is needed with
rounding mode being set to RoundingMode
StrictMath public static int
toIntExact(long value)
if the
argument overflows an int