@Override public ImmutableSet<T> findObjectsInRect(Point min, Point max) { return delegate().findObjectsInRect(min, max); }
@Test public void findObjectsInRectTest() { assertThat(reg.findObjectsInRect(new Point(0, 0), new Point(1, 1))) .isEmpty(); reg.addAt(A, new Point(1, 0)); reg.addAt(B, new Point(0, 0)); reg.addAt(C, new Point(1.1, 0)); reg.addAt(D, new Point(.5, .5)); reg.addAt(E, new Point(5, 5)); assertThat(reg.findObjectsInRect(new Point(0, 0), new Point(1, 1))) .containsExactly(A, B, D); }