private ContainingViewportBuilder add(final ICoordinate point) {
            if (point == null) {
                return this;
            }
            viewport = null;
            final Geopoint coords = point.getCoords();
            if (coords != null) {
                valid = true;
                final double latitude = coords.getLatitude();
                final double longitude = coords.getLongitude();
                latMin = Math.min(latMin, latitude);
                latMax = Math.max(latMax, latitude);
                lonMin = Math.min(lonMin, longitude);
                lonMax = Math.max(lonMax, longitude);
            }
            return this;
        }
Helper class to build Viewports without instanciating too many helper objects
main/src/main/java/cgeo/geocaching/location/Viewport.java