Class ExactMath
java.lang.Object
org.apache.commons.compress.utils.ExactMath
PRIVATE.
Performs exact math through
Math
"exact" APIs.-
Method Summary
Modifier and TypeMethodDescriptionstatic int
add
(int x, long y) Returns the int result of adding an int and a long, and throws an exception if the result overflows an int.
-
Method Details
-
add
Returns the int result of adding an int and a long, and throws an exception if the result overflows an int.- Parameters:
x
- the first value, an int.y
- the second value, a long,- Returns:
- the addition of both values.
- Throws:
IllegalArgumentException
- when y or the result overflows an int
-