QGIS API Documentation  2.18.21-Las Palmas (9fba24a)
qgsmultilinestringv2.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgsmultilinestringv2.h
3  -------------------------------------------------------------------
4 Date : 28 Oct 2014
5 Copyright : (C) 2014 by Marco Hugentobler
6 email : marco.hugentobler at sourcepole dot com
7  ***************************************************************************
8  * *
9  * This program is free software; you can redistribute it and/or modify *
10  * it under the terms of the GNU General Public License as published by *
11  * the Free Software Foundation; either version 2 of the License, or *
12  * (at your option) any later version. *
13  * *
14  ***************************************************************************/
15 
16 #ifndef QGSMULTILINESTRINGV2_H
17 #define QGSMULTILINESTRINGV2_H
18 
19 #include "qgsmulticurvev2.h"
20 
27 class CORE_EXPORT QgsMultiLineStringV2: public QgsMultiCurveV2
28 {
29  public:
31  virtual QString geometryType() const override { return "MultiLineString"; }
32  QgsMultiLineStringV2* clone() const override;
33 
34  bool fromWkt( const QString& wkt ) override;
35 
36  // inherited: int wkbSize() const;
37  // inherited: unsigned char* asWkb( int& binarySize ) const;
38  // inherited: QString asWkt( int precision = 17 ) const;
39  QDomElement asGML2( QDomDocument& doc, int precision = 17, const QString& ns = "gml" ) const override;
40  QDomElement asGML3( QDomDocument& doc, int precision = 17, const QString& ns = "gml" ) const override;
41  QString asJSON( int precision = 17 ) const override;
42 
44  virtual bool addGeometry( QgsAbstractGeometryV2* g ) override;
45 
48  QgsAbstractGeometryV2* toCurveType() const override;
49 
50  protected:
51 
52  virtual bool wktOmitChildType() const override { return true; }
53 };
54 
55 #endif // QGSMULTILINESTRINGV2_H
virtual bool wktOmitChildType() const override
Returns whether child type names are omitted from Wkt representations of the collection.
QDomElement asGML3(QDomDocument &doc, int precision=17, const QString &ns="gml") const override
Returns a GML3 representation of the geometry.
Multi curve geometry collection.
QgsMultiCurveV2 * clone() const override
Clones the geometry by performing a deep copy.
Abstract base class for all geometries.
bool fromWkt(const QString &wkt) override
Sets the geometry from a WKT string.
Multi line string geometry collection.
virtual QgsAbstractGeometryV2 * toCurveType() const
Returns the geometry converted to the more generic curve type.
virtual bool addGeometry(QgsAbstractGeometryV2 *g) override
Adds a geometry and takes ownership.
virtual QString geometryType() const override
Returns a unique string representing the geometry type.
QString asJSON(int precision=17) const override
Returns a GeoJSON representation of the geometry.
QDomElement asGML2(QDomDocument &doc, int precision=17, const QString &ns="gml") const override
Returns a GML2 representation of the geometry.