Skip to content

Commit

Permalink
Initialize in construction (#219)
Browse files Browse the repository at this point in the history
  • Loading branch information
jklamer authored and MikeGost committed Sep 19, 2018
1 parent 8857488 commit c7ea7d4
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
import org.openstreetmap.atlas.geography.GeometricSurface;
import org.openstreetmap.atlas.geography.MultiPolygon;
import org.openstreetmap.atlas.geography.Polygon;
import org.openstreetmap.atlas.geography.Rectangle;
import org.openstreetmap.atlas.geography.atlas.items.AtlasEntity;
import org.openstreetmap.atlas.geography.converters.PolygonStringFormat;
import org.openstreetmap.atlas.geography.index.RTree;
Expand Down Expand Up @@ -159,6 +160,8 @@ private AtlasEntityPolygonsFilter(final Type filterType,
this.intersectionPolicy = intersectionPolicy;
this.geometricSurfaces = (RTree<GeometricSurface>) RTree
.forLocated(geometricSurfaces == null ? Collections.EMPTY_SET : geometricSurfaces);
// initialize underlying STR tree
this.geometricSurfaces.get(Rectangle.MAXIMUM);
}

@Override
Expand Down

0 comments on commit c7ea7d4

Please sign in to comment.