Interface BigIntegerStatisticResult
- All Superinterfaces:
DoubleSupplier, IntSupplier, LongSupplier, StatisticResult
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
BigInteger result of a statistic computed over a set of values.
This is a helper interface to map the native type of the expected value to other result types.
- Since:
- 1.1
-
Method Summary
Modifier and TypeMethodDescriptionGets a result as aBigInteger.default doubledefault intgetAsInt()default long
-
Method Details
-
getAsBigInteger
BigInteger getAsBigInteger()Description copied from interface:StatisticResultGets a result as aBigInteger.The default implementation uses the closest representable
BigIntegervalue of theDoubleSupplier.getAsDouble()result. In the event of ties the result is rounded towards positive infinity. This will raise anArithmeticExceptionif theresultis not finite.- Specified by:
getAsBigIntegerin interfaceStatisticResult- Returns:
- a result
-
getAsDouble
default double getAsDouble()- Specified by:
getAsDoublein interfaceDoubleSupplier
-
getAsInt
default int getAsInt()Description copied from interface:StatisticResultThe default implementation uses the closest representable
intvalue of theDoubleSupplier.getAsDouble()result. In the event of ties the result is rounded towards positive infinity. This will raise anArithmeticExceptionif the closest integer result is not within the range[-2^31, 2^31).- Specified by:
getAsIntin interfaceIntSupplier- Specified by:
getAsIntin interfaceStatisticResult
-
getAsLong
default long getAsLong()Description copied from interface:StatisticResultThe default implementation uses the closest representable
longvalue of theDoubleSupplier.getAsDouble()result. In the event of ties the result is rounded towards positive infinity. This will raise anArithmeticExceptionif the closest integer result is not within the range[-2^63, 2^63).- Specified by:
getAsLongin interfaceLongSupplier- Specified by:
getAsLongin interfaceStatisticResult
-