Skip to content

Commit

Permalink
Fixes to make sure each header can be compiled in a standalone way
Browse files Browse the repository at this point in the history
Verified with
``find include -name "*.h" -exec g++ -c {} -Iinclude -DUSE_UNSTABLE_GEOS_CPP_API \;``
  • Loading branch information
rouault committed Oct 5, 2024
1 parent 928feee commit 325cc64
Show file tree
Hide file tree
Showing 10 changed files with 25 additions and 8 deletions.
1 change: 1 addition & 0 deletions include/geos/edgegraph/MarkHalfEdge.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#pragma once

#include <geos/geom/Coordinate.h>
#include <geos/edgegraph/HalfEdge.h>

#include <geos/export.h>
#include <string>
Expand Down
3 changes: 3 additions & 0 deletions include/geos/geom/prep/PreparedLineStringDistance.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@

namespace geos {
namespace geom { // geos::geom

class Geometry;

namespace prep { // geos::geom::prep

class PreparedLineString;
Expand Down
7 changes: 7 additions & 0 deletions include/geos/geom/prep/PreparedLineStringNearestPoints.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,15 @@

#pragma once

#include <memory>

#include <geos/geom/prep/PreparedLineString.h>

namespace geos {
namespace geom { // geos::geom

class CoordinateSequence;

namespace prep { // geos::geom::prep

class PreparedLineStringNearestPoints {
Expand Down
1 change: 1 addition & 0 deletions include/geos/linearref/LocationIndexedLine.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#include <geos/export.h>
#include <geos/geom/Coordinate.h>
#include <geos/geom/Geometry.h>
#include <geos/linearref/ExtractLineByLocation.h>
#include <geos/linearref/LinearLocation.h>
#include <geos/linearref/LocationIndexOfPoint.h>
#include <geos/linearref/LocationIndexOfLine.h>
Expand Down
1 change: 1 addition & 0 deletions include/geos/operation/relateng/EdgeSetIntersector.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ using geos::geom::Envelope;
using geos::geom::Geometry;
using geos::index::strtree::TemplateSTRtree;
using geos::index::chain::MonotoneChain;
using geos::noding::SegmentString;
using geos::operation::relateng::EdgeSegmentIntersector;


Expand Down
2 changes: 2 additions & 0 deletions include/geos/operation/union/CascadedPolygonUnion.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@

#pragma once

#include <vector>

#include <geos/export.h>

#include <geos/operation/union/UnionStrategy.h>
Expand Down
1 change: 1 addition & 0 deletions include/geos/operation/union/PointGeometryUnion.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

#include <vector>
#include <algorithm>
#include <memory>

// Forward declarations
namespace geos {
Expand Down
1 change: 1 addition & 0 deletions include/geos/triangulate/polygon/PolygonHoleJoiner.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ namespace geom {
class Envelope;
class Geometry;
class LinearRing;
class Polygon;
}
namespace noding {
}
Expand Down
7 changes: 7 additions & 0 deletions include/geos/triangulate/polygon/PolygonNoder.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@
// #include <geos/geom/Coordinate.h>
//#include <geos/geom/CoordinateSequence.h>

#include <geos/export.h>

#include <map>
#include <memory>
#include <vector>

// Forward declarations
namespace geos {
Expand All @@ -29,6 +33,9 @@ class CoordinateSequence;
namespace noding {
class NodedSegmentString;
}
namespace algorithm {
class LineIntersector;
}
}

using geos::geom::Coordinate;
Expand Down
9 changes: 1 addition & 8 deletions include/geos/triangulate/tri/TriEdge.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,9 @@
#pragma once

#include <geos/export.h>
#include <geos/geom/Coordinate.h>
#include <iostream>


// Forward declarations
namespace geos {
namespace geom {
class Coordinate;
}
}

using geos::geom::Coordinate;

namespace geos { // geos.
Expand Down

0 comments on commit 325cc64

Please sign in to comment.