cassandra-analytics-core/src/main/java/org/apache/cassandra/spark/bulkwriter/token/RangeUtils.java [47:70]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public static BigInteger sizeOf(Range<BigInteger> range)
    {
        Preconditions.checkArgument(range.lowerEndpoint().compareTo(range.upperEndpoint()) <= 0,
                                    "RangeUtils assume ranges are not wrap-around");

        if (range.isEmpty())
        {
            return BigInteger.ZERO;
        }

        BigInteger size = range.upperEndpoint().subtract(range.lowerEndpoint()).add(BigInteger.ONE);

        if (range.lowerBoundType() == BoundType.OPEN)
        {
            size = size.subtract(BigInteger.ONE);
        }

        if (range.upperBoundType() == BoundType.OPEN)
        {
            size = size.subtract(BigInteger.ONE);
        }

        return size;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



cassandra-analytics-core/src/main/java/org/apache/cassandra/spark/utils/RangeUtils.java [51:74]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    private static BigInteger sizeOf(@NotNull Range<BigInteger> range)
    {
        Preconditions.checkArgument(range.lowerEndpoint().compareTo(range.upperEndpoint()) <= 0,
                                    "RangeUtils assume ranges are not wrap-around");

        if (range.isEmpty())
        {
            return BigInteger.ZERO;
        }

        BigInteger size = range.upperEndpoint().subtract(range.lowerEndpoint()).add(BigInteger.ONE);

        if (range.lowerBoundType() == BoundType.OPEN)
        {
            size = size.subtract(BigInteger.ONE);
        }

        if (range.upperBoundType() == BoundType.OPEN)
        {
            size = size.subtract(BigInteger.ONE);
        }

        return size;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



