BigInteger.intValueExact

Converts this {@code BigInteger} to an {@code int}, checking for lost information. If the value of this {@code BigInteger} is out of the range of the {@code int} type, then an {@code ArithmeticException} is thrown.

@return this {@code BigInteger} converted to an {@code int}. @throws ArithmeticException if the value of {@code this} will not exactly fit in an {@code int}. @see BigInteger#intValue

class BigInteger
int
intValueExact
()

Meta