00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef GEOS_GEOS_LINEARRING_H
00021 #define GEOS_GEOS_LINEARRING_H
00022
00023 #include <geos/export.h>
00024 #include <string>
00025 #include <vector>
00026 #include <geos/platform.h>
00027 #include <geos/geom/LineString.h>
00028
00029 #include <geos/inline.h>
00030
00031
00032 namespace geos {
00033 namespace geom {
00034 class Coordinate;
00035 class CoordinateArraySequence;
00036 }
00037 }
00038
00039 namespace geos {
00040 namespace geom {
00041
00057 class GEOS_DLL LinearRing : public LineString {
00058
00059 public:
00060
00065 static const unsigned int MINIMUM_VALID_SIZE = 4;
00066
00067 LinearRing(const LinearRing &lr);
00068
00081 LinearRing(CoordinateSequence* points,
00082 const GeometryFactory *newFactory);
00083
00085 LinearRing(CoordinateSequence::AutoPtr points,
00086 const GeometryFactory *newFactory);
00087
00088 virtual Geometry *clone() const { return new LinearRing(*this); }
00089
00090 virtual ~LinearRing();
00091
00098 int getBoundaryDimension() const;
00099
00108 bool isSimple() const;
00109
00110 bool isClosed() const;
00111
00112 std::string getGeometryType() const;
00113
00114 virtual GeometryTypeId getGeometryTypeId() const;
00115
00116 void setPoints(CoordinateSequence* cl);
00117
00118 Geometry* reverse() const;
00119
00120 private:
00121
00122 void validateConstruction();
00123 };
00124
00125
00126 }
00127 }
00128
00129 #endif // ndef GEOS_GEOS_LINEARRING_H