@Test public void testRangesEqual() { LongTokenRange range1 = new LongTokenRange(1, 2); LongTokenRange range2 = new LongTokenRange(1, 2); assertThat(range1).isEqualTo(range2); assertThat(range1.hashCode()).isEqualTo(range2.hashCode()); }
@Override public int hashCode() { int result = (int) (start ^ (start >>> 32)); result = 31 * result + (int) (end ^ (end >>> 32)); return result; }
LongTokenRange { @Override public int hashCode() { int result = (int) (start ^ (start >>> 32)); result = 31 * result + (int) (end ^ (end >>> 32)); return result; } }
LongTokenRange { @Override public int hashCode() { int result = (int) (start ^ (start >>> 32)); result = 31 * result + (int) (end ^ (end >>> 32)); return result; } LongTokenRange(long start, long end); }
LongTokenRange { @Override public int hashCode() { int result = (int) (start ^ (start >>> 32)); result = 31 * result + (int) (end ^ (end >>> 32)); return result; } LongTokenRange(long start, long end); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); }
LongTokenRange { @Override public int hashCode() { int result = (int) (start ^ (start >>> 32)); result = 31 * result + (int) (end ^ (end >>> 32)); return result; } LongTokenRange(long start, long end); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode(); final long start; final long end; }