@Test public void include() throws Exception { ReferencedEnvelope3D australia = new ReferencedEnvelope3D(DefaultGeographicCRS.WGS84_3D); australia.include(40, 110, 0); australia.include(10, 150, 10); ReferencedEnvelope3D newZealand = new ReferencedEnvelope3D(DefaultEngineeringCRS.CARTESIAN_3D); newZealand.include(50, 165, 0); newZealand.include(33, 180, 5); try { australia.expandToInclude(newZealand); fail("Expected a mismatch of CoordinateReferenceSystem"); } catch (MismatchedReferenceSystemException t) { } try { australia.include(newZealand); fail("Expected a mismatch of CoordinateReferenceSystem"); } catch (MismatchedReferenceSystemException t) { } }
public void include(final BoundingBox3D bbox) { if (crs == null) { this.crs = bbox.getCoordinateReferenceSystem(); } expandToInclude(getJTSEnvelope(bbox)); }
ReferencedEnvelope3D extends ReferencedEnvelope implements BoundingBox3D { public void include(final BoundingBox3D bbox) { if (crs == null) { this.crs = bbox.getCoordinateReferenceSystem(); } expandToInclude(getJTSEnvelope(bbox)); } }
ReferencedEnvelope3D extends ReferencedEnvelope implements BoundingBox3D { public void include(final BoundingBox3D bbox) { if (crs == null) { this.crs = bbox.getCoordinateReferenceSystem(); } expandToInclude(getJTSEnvelope(bbox)); } ReferencedEnvelope3D();  ReferencedEnvelope3D(CoordinateReferenceSystem crs);  ReferencedEnvelope3D(
            final double x1,
            final double x2,
            final double y1,
            final double y2,
            final double z1,
            final double z2,
            final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final ReferencedEnvelope3D envelope);  ReferencedEnvelope3D(final BoundingBox3D bbox);  ReferencedEnvelope3D(final Envelope envelope, final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final org.opengis.geometry.Envelope envelope);  ReferencedEnvelope3D(
            final ReferencedEnvelope3D envelope, final CoordinateReferenceSystem crs); }
ReferencedEnvelope3D extends ReferencedEnvelope implements BoundingBox3D { public void include(final BoundingBox3D bbox) { if (crs == null) { this.crs = bbox.getCoordinateReferenceSystem(); } expandToInclude(getJTSEnvelope(bbox)); } ReferencedEnvelope3D();  ReferencedEnvelope3D(CoordinateReferenceSystem crs);  ReferencedEnvelope3D(
            final double x1,
            final double x2,
            final double y1,
            final double y2,
            final double z1,
            final double z2,
            final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final ReferencedEnvelope3D envelope);  ReferencedEnvelope3D(final BoundingBox3D bbox);  ReferencedEnvelope3D(final Envelope envelope, final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final org.opengis.geometry.Envelope envelope);  ReferencedEnvelope3D(
            final ReferencedEnvelope3D envelope, final CoordinateReferenceSystem crs); static boolean intersects(Coordinate p1, Coordinate p2, Coordinate q); static boolean intersects(Coordinate p1, Coordinate p2, Coordinate q1, Coordinate q2); void init(); void init(double x1, double x2, double y1, double y2, double z1, double z2); void init(Coordinate p1, Coordinate p2); void init(Coordinate p); @Override void init(Envelope env); void init(ReferencedEnvelope3D env); void setToNull(); double getDepth(); double getMinZ(); double getMaxZ(); double getVolume(); double minExtent(); double maxExtent(); void expandToInclude(Coordinate p); void expandBy(double distance); void expandBy(double deltaX, double deltaY, double deltaZ); void expandToInclude(double x, double y, double z); @Override void expandToInclude(DirectPosition pt); void translate(double transX, double transY, double transZ); Coordinate centre(); boolean intersects(ReferencedEnvelope3D other); boolean intersects(Coordinate p); @SuppressWarnings("deprecation") boolean overlaps(Coordinate p); boolean intersects(double x, double y, double z); boolean contains(Coordinate p); boolean contains(double x, double y, double z); boolean covers(double x, double y, double z); boolean covers(Coordinate p); boolean covers(ReferencedEnvelope3D other); double distance(ReferencedEnvelope3D env); void init(BoundingBox bounds); int getDimension(); double getMinimum(final int dimension); double getMaximum(final int dimension); double getMedian(final int dimension); double getSpan(final int dimension); DirectPosition getLowerCorner(); DirectPosition getUpperCorner(); boolean isEmpty(); boolean contains(DirectPosition pos); boolean contains(final BoundingBox3D bbox); boolean intersects(final BoundingBox3D bbox); ReferencedEnvelope3D intersection(ReferencedEnvelope3D env); void include(final BoundingBox3D bbox); void expandToInclude(ReferencedEnvelope3D other); void include(double x, double y, double z); void setBounds(final BoundingBox3D bbox); BoundingBox toBounds(final CoordinateReferenceSystem targetCRS); ReferencedEnvelope transform(CoordinateReferenceSystem targetCRS, boolean lenient); ReferencedEnvelope transform(
            final CoordinateReferenceSystem targetCRS,
            final boolean lenient,
            final int numPointsForTransformation); @Override int hashCode(); @Override boolean equals(final Object other); boolean boundsEquals3D(final org.opengis.geometry.Envelope other, double eps); @Override void include(double x, double y); }
ReferencedEnvelope3D extends ReferencedEnvelope implements BoundingBox3D { public void include(final BoundingBox3D bbox) { if (crs == null) { this.crs = bbox.getCoordinateReferenceSystem(); } expandToInclude(getJTSEnvelope(bbox)); } ReferencedEnvelope3D();  ReferencedEnvelope3D(CoordinateReferenceSystem crs);  ReferencedEnvelope3D(
            final double x1,
            final double x2,
            final double y1,
            final double y2,
            final double z1,
            final double z2,
            final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final ReferencedEnvelope3D envelope);  ReferencedEnvelope3D(final BoundingBox3D bbox);  ReferencedEnvelope3D(final Envelope envelope, final CoordinateReferenceSystem crs);  ReferencedEnvelope3D(final org.opengis.geometry.Envelope envelope);  ReferencedEnvelope3D(
            final ReferencedEnvelope3D envelope, final CoordinateReferenceSystem crs); static boolean intersects(Coordinate p1, Coordinate p2, Coordinate q); static boolean intersects(Coordinate p1, Coordinate p2, Coordinate q1, Coordinate q2); void init(); void init(double x1, double x2, double y1, double y2, double z1, double z2); void init(Coordinate p1, Coordinate p2); void init(Coordinate p); @Override void init(Envelope env); void init(ReferencedEnvelope3D env); void setToNull(); double getDepth(); double getMinZ(); double getMaxZ(); double getVolume(); double minExtent(); double maxExtent(); void expandToInclude(Coordinate p); void expandBy(double distance); void expandBy(double deltaX, double deltaY, double deltaZ); void expandToInclude(double x, double y, double z); @Override void expandToInclude(DirectPosition pt); void translate(double transX, double transY, double transZ); Coordinate centre(); boolean intersects(ReferencedEnvelope3D other); boolean intersects(Coordinate p); @SuppressWarnings("deprecation") boolean overlaps(Coordinate p); boolean intersects(double x, double y, double z); boolean contains(Coordinate p); boolean contains(double x, double y, double z); boolean covers(double x, double y, double z); boolean covers(Coordinate p); boolean covers(ReferencedEnvelope3D other); double distance(ReferencedEnvelope3D env); void init(BoundingBox bounds); int getDimension(); double getMinimum(final int dimension); double getMaximum(final int dimension); double getMedian(final int dimension); double getSpan(final int dimension); DirectPosition getLowerCorner(); DirectPosition getUpperCorner(); boolean isEmpty(); boolean contains(DirectPosition pos); boolean contains(final BoundingBox3D bbox); boolean intersects(final BoundingBox3D bbox); ReferencedEnvelope3D intersection(ReferencedEnvelope3D env); void include(final BoundingBox3D bbox); void expandToInclude(ReferencedEnvelope3D other); void include(double x, double y, double z); void setBounds(final BoundingBox3D bbox); BoundingBox toBounds(final CoordinateReferenceSystem targetCRS); ReferencedEnvelope transform(CoordinateReferenceSystem targetCRS, boolean lenient); ReferencedEnvelope transform(
            final CoordinateReferenceSystem targetCRS,
            final boolean lenient,
            final int numPointsForTransformation); @Override int hashCode(); @Override boolean equals(final Object other); boolean boundsEquals3D(final org.opengis.geometry.Envelope other, double eps); @Override void include(double x, double y); static ReferencedEnvelope3D EVERYTHING; }