code: private Coordinate getLocationWithinMaxBounds(Coordinate original) {
  		double x = original.getX();
  		double y = original.getY();
  		if (maxBounds != null) {
  			if (original.getX() < maxBounds.getX()) {
  				x = maxBounds.getX();
  			} else if (original.getX() > maxBounds.getMaxX()) {
  				x = maxBounds.getMaxX();
  			}
  			if (original.getY() < maxBounds.getY()) {
  				y = maxBounds.getY();
  			} else if (original.getY() > maxBounds.getMaxY()) {
  				y = maxBounds.getMaxY();
  			}
  		}
  		return new Coordinate(x, y);
  	}
docs: Get a location, derived from the original, that is sure to be within the maximum bounds. If no maximum bounds
  have been set, a clone of the original is returned.
  
  @param original
  The original location.
  @return The derived location within the maximum bounds.