@Test public void contains() { Assert.assertFalse(ONE_TEN.contains(BigInteger.ZERO)); Assert.assertTrue(ONE_TEN.contains(BigInteger.ONE)); Assert.assertTrue(ONE_TEN.contains(BigInteger.valueOf(5))); Assert.assertFalse(ONE_TEN.contains(BigInteger.valueOf(10))); Assert.assertFalse(ONE_TEN.contains(BigInteger.valueOf(11))); }
@Override public boolean contains(BigInteger point) { return start.compareTo(point) <= 0 && end.compareTo(point) > 0; }
BigIntegerRange implements Range<BigInteger, BigIntegerContent> { @Override public boolean contains(BigInteger point) { return start.compareTo(point) <= 0 && end.compareTo(point) > 0; } }
BigIntegerRange implements Range<BigInteger, BigIntegerContent> { @Override public boolean contains(BigInteger point) { return start.compareTo(point) <= 0 && end.compareTo(point) > 0; } BigIntegerRange(BigInteger start, BigInteger end); }
BigIntegerRange implements Range<BigInteger, BigIntegerContent> { @Override public boolean contains(BigInteger point) { return start.compareTo(point) <= 0 && end.compareTo(point) > 0; } BigIntegerRange(BigInteger start, BigInteger end); @Override BigInteger getStart(); @Override BigInteger getEnd(); @Override BigIntegerContent length(); static BigIntegerRange of(long start, long end); static BigIntegerRange of(BigInteger start, BigInteger end); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); @Override boolean contains(BigInteger point); }
BigIntegerRange implements Range<BigInteger, BigIntegerContent> { @Override public boolean contains(BigInteger point) { return start.compareTo(point) <= 0 && end.compareTo(point) > 0; } BigIntegerRange(BigInteger start, BigInteger end); @Override BigInteger getStart(); @Override BigInteger getEnd(); @Override BigIntegerContent length(); static BigIntegerRange of(long start, long end); static BigIntegerRange of(BigInteger start, BigInteger end); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object obj); @Override boolean contains(BigInteger point);  }