17#include <geos/geom/SimpleCurve.h>
24class GEOS_DLL CompoundCurve :
public Curve {
25 friend class GeometryFactory;
28 using Curve::apply_ro;
29 using Curve::apply_rw;
31 void apply_ro(CoordinateFilter* filter)
const override;
33 void apply_ro(CoordinateSequenceFilter& filter)
const override;
35 void apply_rw(CoordinateSequenceFilter& filter)
override;
37 void apply_rw(
const CoordinateFilter* filter)
override;
39 int compareToSameClass(
const Geometry* geom)
const override;
41 std::unique_ptr<CompoundCurve> clone()
const;
43 bool equalsExact(
const Geometry* other,
double tolerance = 0)
46 bool equalsIdentical(
const Geometry* other)
const override;
48 std::unique_ptr<Geometry> getBoundary()
const override;
50 const CoordinateXY* getCoordinate()
const override;
52 uint8_t getCoordinateDimension()
const override;
54 std::unique_ptr<CoordinateSequence> getCoordinates()
const override;
57 const SimpleCurve* getCurveN(std::size_t)
const override;
59 std::unique_ptr<Point> getEndPoint()
const override;
61 const Envelope* getEnvelopeInternal()
const override
66 std::string getGeometryType()
const override;
70 double getLength()
const override;
73 std::size_t getNumCurves()
const override;
75 std::size_t getNumPoints()
const override;
77 std::unique_ptr<Point> getPointN(std::size_t n)
const override;
79 std::unique_ptr<Point> getStartPoint()
const override;
81 bool hasCurvedComponents()
const override;
83 bool hasM()
const override;
85 bool hasZ()
const override;
87 bool isClosed()
const override;
89 bool isEmpty()
const override;
91 void normalize()
override;
93 std::unique_ptr<CompoundCurve> reverse()
const;
95 void validateConstruction()
const;
100 CompoundCurve(std::vector<std::unique_ptr<SimpleCurve>>&&,
101 const GeometryFactory&);
103 CompoundCurve(
const CompoundCurve&);
105 CompoundCurve& operator=(
const CompoundCurve&);
107 CompoundCurve* cloneImpl()
const override;
109 Envelope computeEnvelopeInternal()
const;
111 void geometryChangedAction()
override
113 envelope = computeEnvelopeInternal();
116 int getSortIndex()
const override
118 return SORTINDEX_COMPOUNDCURVE;
121 CompoundCurve* reverseImpl()
const override;
124 void normalizeClosed();
126 void reverseInPlace();
128 std::vector<std::unique_ptr<SimpleCurve>> curves;
GeometryTypeId
Geometry types.
Definition Geometry.h:73
Basic namespace for all GEOS functionalities.
Definition geos.h:38