23 #include <geos/export.h>
24 #include <geos/io/OrdinateSet.h>
32 #pragma warning(disable: 4251)
41 class CoordinateSequence;
45 class GeometryCollection;
51 class MultiLineString;
105 void writeFormatted(
const geom::Geometry* geometry, Writer* writer);
124 static std::string
toLineString(
const geom::CoordinateXY& p0,
const geom::CoordinateXY& p1);
134 static std::string toPoint(
const geom::CoordinateXY& p0);
162 removeEmptyDimensions = remove;
187 getOutputDimension()
const
189 return defaultOutputDimension;
200 void setOutputDimension(uint8_t newOutputDimension);
202 static std::string writeNumber(
double d,
bool trim, uint32_t precision);
203 static int writeTrimmedNumber(
double d, uint32_t precision,
char* buf);
209 void appendGeometryTaggedText(
211 OrdinateSet outputOrdinates,
213 Writer& writer)
const;
217 OrdinateSet outputOrdinates,
218 Writer& writer)
const;
220 void appendPointTaggedText(
222 OrdinateSet outputOrdinates,
223 int level, Writer& writer)
const;
225 void appendSimpleCurveTaggedText(
226 const geom::SimpleCurve& lineString,
227 OrdinateSet outputOrdinates,
228 int level, Writer& writer)
const;
230 void appendCompoundCurveTaggedText(
231 const geom::CompoundCurve& lineString,
232 OrdinateSet outputOrdinates,
233 int level, Writer& writer)
const;
235 void appendSurfaceTaggedText(
237 OrdinateSet outputOrdinates,
238 int level, Writer& writer)
const;
240 void appendMultiPointTaggedText(
242 OrdinateSet outputOrdinates,
243 int level, Writer& writer)
const;
245 void appendMultiCurveTaggedText(
247 OrdinateSet outputOrdinates,
248 int level, Writer& writer)
const;
250 void appendMultiSurfaceTaggedText(
252 OrdinateSet outputOrdinates,
253 int level, Writer& writer)
const;
255 void appendGeometryCollectionTaggedText(
257 OrdinateSet outputOrdinates,
258 int level, Writer& writer)
const;
260 void appendOrdinateText(OrdinateSet outputOrdinates,
261 Writer& writer)
const;
264 OrdinateSet outputOrdinates,
267 Writer& writer)
const;
269 void appendCoordinate(
const geom::CoordinateXYZM& coordinate,
270 OrdinateSet outputOrdinates,
271 Writer& writer)
const;
273 std::string writeNumber(
double d)
const;
275 void appendCurveText(
276 const geom::Curve& lineString,
277 OrdinateSet outputOrdinates,
278 int level,
bool doIndent, Writer& writer)
const;
280 void appendSimpleCurveText(
281 const geom::SimpleCurve& lineString,
282 OrdinateSet outputOrdinates,
283 int level,
bool doIndent, Writer& writer)
const;
285 void appendSurfaceText(
287 OrdinateSet outputOrdinates,
288 int level,
bool indentFirst, Writer& writer)
const;
290 void appendMultiPointText(
292 OrdinateSet outputOrdinates,
293 int level, Writer& writer)
const;
295 void appendMultiCurveText(
297 OrdinateSet outputOrdinates,
298 int level,
bool indentFirst, Writer& writer)
const;
300 void appendMultiSurfaceText(
302 OrdinateSet outputOrdinates,
303 int level, Writer& writer)
const;
305 void appendGeometryCollectionText(
307 OrdinateSet outputOrdinates,
308 int level, Writer& writer)
const;
318 int roundingPrecision;
322 bool removeEmptyDimensions =
false;
324 static constexpr
int coordsPerLine = 10;
326 uint8_t defaultOutputDimension;
330 const geom::Geometry* geometry,
331 bool isFormatted, Writer* writer);
333 void indent(
int level, Writer* writer)
const;
The internal representation of a list of coordinates inside a Geometry.
Definition: CoordinateSequence.h:56
Coordinate is the lightweight class used to store coordinates.
Definition: Coordinate.h:217
Represents a collection of heterogeneous Geometry objects.
Definition: GeometryCollection.h:51
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition: Geometry.h:197
Definition: MultiPoint.h:50
Outputs the textual representation of a Geometry. See also WKTReader.
Definition: WKTWriter.h:87
static std::string toPoint(const geom::Coordinate &p0)
void setOld3D(bool useOld3D)
Definition: WKTWriter.h:176
void setRoundingPrecision(int p0)
static std::string toLineString(const geom::CoordinateXY &p0, const geom::CoordinateXY &p1)
std::string write(const geom::Geometry *geometry)
Returns WKT string for the given Geometry.
void setRemoveEmptyDimensions(bool remove)
setRemoveEmptyDimensions
Definition: WKTWriter.h:160
static std::string toLineString(const geom::CoordinateSequence &seq)
Basic namespace for all GEOS functionalities.
Definition: Angle.h:25