### Question:
BoundingBoxImpl extends AbstractPolygon implements BoundingBox { @Override public boolean contains(double x, double y) { CoordinateSystem coordinateSystem = crs.getCoordinateSystem(); if (coordinateSystem.getDimension() >= 2) { if (coordinateSystem.getAxis(0).getRangeMeaning() == RangeMeaning.WRAPAROUND) { x = GISUtils.getNextEquivalentLongitude(minx, x); } if (coordinateSystem.getAxis(1).getRangeMeaning() == RangeMeaning.WRAPAROUND) { y = GISUtils.getNextEquivalentLongitude(miny, y); } } return (x >= minx && x <= maxx && y >= miny && y <= maxy); } BoundingBoxImpl(double minx, double miny, double maxx, double maxy);  BoundingBoxImpl(double minx, double miny, double maxx, double maxy,
            CoordinateReferenceSystem crs);  BoundingBoxImpl(Extent<Double> xExtent, Extent<Double> yExtent,
            CoordinateReferenceSystem crs);  BoundingBoxImpl(GeographicBoundingBox gbb);  BoundingBoxImpl(CoordinateReferenceSystem crs); static BoundingBoxImpl global(); @Override CoordinateReferenceSystem getCoordinateReferenceSystem(); @Override double getMinX(); @Override double getMaxX(); @Override double getMinY(); @Override double getMaxY(); @Override double getWidth(); @Override double getHeight(); @Override HorizontalPosition getLowerCorner(); @Override HorizontalPosition getUpperCorner(); @Override String toString(); @Override List<HorizontalPosition> getVertices(); @Override boolean contains(double x, double y); @Override BoundingBox getBoundingBox(); @Override int hashCode(); @Override boolean equals(Object obj);  }### Answer:
@Test public void testContains() throws InvalidCrsException { HorizontalPosition hPos = new HorizontalPosition(160.0, -20.0, GISUtils.defaultGeographicCRS()); assertTrue(bbox.contains(hPos)); hPos = new HorizontalPosition(150.0, 50.0, GISUtils.defaultGeographicCRS()); assertTrue(bbox.contains(hPos)); assertTrue(bbox.contains(137.47, -20.0)); assertTrue(bbox.contains(137.47, 40.0)); assertTrue(bbox.contains(137.47, 60.0)); assertTrue(bbox.contains(150.0, -20.0)); assertTrue(bbox.contains(180.0, -20.0)); assertTrue(bbox.contains(180.0, 60.0)); assertTrue(bbox.contains(180.0, 30.0)); assertTrue(bbox.contains(160.0, 60.0)); assertFalse(bbox.contains(190, 0.0)); assertFalse(bbox.contains(Double.NaN, -30.0)); assertFalse(bbox.contains(null)); CoordinateReferenceSystem japanArea = GISUtils.getCrs("EPSG:2450"); assertTrue(bbox.contains(new HorizontalPosition(17945.194292, 41625.344542, japanArea))); CoordinateReferenceSystem chinaArea = GISUtils.getCrs("EPSG:2426"); assertFalse(bbox.contains(new HorizontalPosition(500000, 4261964.001513, chinaArea))); }