QGIS API Documentation  2.12.0-Lyon
qgspolygonv2.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgspolygonv2.h
3  -------------------
4  begin : September 2014
5  copyright : (C) 2014 by Marco Hugentobler
6  email : marco at sourcepole dot ch
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * This program is free software; you can redistribute it and/or modify *
12  * it under the terms of the GNU General Public License as published by *
13  * the Free Software Foundation; either version 2 of the License, or *
14  * (at your option) any later version. *
15  * *
16  ***************************************************************************/
17 
18 #ifndef QGSPOLYGONV2_H
19 #define QGSPOLYGONV2_H
20 
21 #include "qgscurvepolygonv2.h"
22 
29 class CORE_EXPORT QgsPolygonV2: public QgsCurvePolygonV2
30 {
31  public:
32  virtual QString geometryType() const override { return "Polygon"; }
33  virtual QgsPolygonV2* clone() const override;
34 
35  virtual bool fromWkb( const unsigned char* wkb ) override;
36  // inherited: bool fromWkt( const QString &wkt );
37 
38  int wkbSize() const override;
39  unsigned char* asWkb( int& binarySize ) const override;
40  // inherited: QString asWkt( int precision = 17 ) const;
41  // inherited: QDomElement asGML2( QDomDocument& doc, int precision = 17, const QString& ns = "gml" ) const;
42  // inherited: QDomElement asGML3( QDomDocument& doc, int precision = 17, const QString& ns = "gml" ) const;
43  // inherited: QString asJSON( int precision = 17 ) const;
44 
45  QgsPolygonV2* surfaceToPolygon() const override;
46 };
47 #endif // QGSPOLYGONV2_H
virtual QString geometryType() const override
Returns a unique string representing the geometry type.
Definition: qgspolygonv2.h:32
QgsPolygonV2 * surfaceToPolygon() const override
int wkbSize() const override
Returns the size of the WKB representation of the geometry.
Polygon geometry type.
Definition: qgspolygonv2.h:29
unsigned char * asWkb(int &binarySize) const override
Returns a WKB representation of the geometry.
virtual QgsCurvePolygonV2 * clone() const override
Clones the geometry by performing a deep copy.
virtual bool fromWkb(const unsigned char *wkb) override
Sets the geometry from a WKB string.
Curve polygon geometry type.