QGIS/python/core/auto_generated/geometry/qgsgeometrycollection.sip.in

219 lines
6.4 KiB
Plaintext
Raw Normal View History

2017-04-27 07:55:22 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/geometry/qgsgeometrycollection.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsGeometryCollection: QgsAbstractGeometry
2015-05-15 15:41:56 +02:00
{
2017-04-27 07:55:22 +02:00
%Docstring
Geometry collection
2017-12-15 10:36:55 -04:00
2017-04-27 07:55:22 +02:00
.. versionadded:: 2.10
2015-05-15 15:41:56 +02:00
%End
2017-04-27 07:55:22 +02:00
%TypeHeaderCode
#include "qgsgeometrycollection.h"
%End
2015-05-15 15:41:56 +02:00
public:
2016-08-06 11:01:42 +02:00
QgsGeometryCollection();
2017-04-27 07:55:22 +02:00
QgsGeometryCollection( const QgsGeometryCollection &c );
~QgsGeometryCollection();
2015-05-15 15:41:56 +02:00
virtual bool operator==( const QgsAbstractGeometry &other ) const;
virtual bool operator!=( const QgsAbstractGeometry &other ) const;
2017-04-27 07:55:22 +02:00
virtual QgsGeometryCollection *clone() const /Factory/;
2015-05-15 15:41:56 +02:00
int numGeometries() const;
2017-04-27 07:55:22 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Returns the number of geometries within the collection.
2017-04-27 07:55:22 +02:00
%End
2016-01-28 10:30:06 +01:00
2017-04-27 07:55:22 +02:00
QgsAbstractGeometry *geometryN( int n );
%Docstring
2017-12-15 10:36:55 -04:00
Returns a geometry from within the collection.
2017-12-15 21:36:08 -04:00
:param n: index of geometry to return
2017-04-27 07:55:22 +02:00
%End
virtual bool isEmpty() const;
2015-05-15 15:41:56 +02:00
virtual int dimension() const;
2015-05-15 15:41:56 +02:00
virtual QString geometryType() const;
2015-05-15 15:41:56 +02:00
virtual void clear();
virtual QgsGeometryCollection *snappedToGrid( double hSpacing, double vSpacing, double dSpacing = 0, double mSpacing = 0 ) const /Factory/;
virtual bool removeDuplicateNodes( double epsilon = 4 * DBL_EPSILON, bool useZValues = false );
2017-04-27 07:55:22 +02:00
virtual QgsAbstractGeometry *boundary() const /Factory/;
2015-05-15 15:41:56 +02:00
virtual void adjacentVertices( QgsVertexId vertex, QgsVertexId &previousVertex /Out/, QgsVertexId &nextVertex /Out/ ) const;
virtual int vertexNumberFromVertexId( QgsVertexId id ) const;
2017-04-27 07:55:22 +02:00
virtual bool addGeometry( QgsAbstractGeometry *g /Transfer/ );
%Docstring
Adds a geometry and takes ownership. Returns true in case of success.
%End
virtual bool insertGeometry( QgsAbstractGeometry *g /Transfer/, int index );
2017-04-27 07:55:22 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Inserts a geometry before a specified index and takes ownership. Returns true in case of success.
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param g: geometry to insert. Ownership is transferred to the collection.
:param index: position to insert geometry before
2017-04-27 07:55:22 +02:00
%End
2015-05-15 15:41:56 +02:00
virtual bool removeGeometry( int nr );
2017-04-27 07:55:22 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Removes a geometry from the collection.
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param nr: index of geometry to remove
:return: true if removal was successful.
2017-04-27 07:55:22 +02:00
%End
2015-05-15 15:41:56 +02:00
virtual void transform( const QgsCoordinateTransform &ct, QgsCoordinateTransform::TransformDirection d = QgsCoordinateTransform::ForwardTransform, bool transformZ = false ) throw( QgsCsException );
virtual void transform( const QTransform &t, double zTranslate = 0.0, double zScale = 1.0, double mTranslate = 0.0, double mScale = 1.0 );
2016-01-28 10:30:06 +01:00
2017-04-27 07:55:22 +02:00
virtual void draw( QPainter &p ) const;
2016-01-28 10:30:06 +01:00
2017-04-27 07:55:22 +02:00
virtual bool fromWkb( QgsConstWkbPtr &wkb );
virtual bool fromWkt( const QString &wkt );
2017-04-27 07:55:22 +02:00
virtual QByteArray asWkb() const;
virtual QString asWkt( int precision = 17 ) const;
virtual QDomElement asGml2( QDomDocument &doc, int precision = 17, const QString &ns = "gml", QgsAbstractGeometry::AxisOrder axisOrder = QgsAbstractGeometry::AxisOrder::XY ) const;
2017-04-27 07:55:22 +02:00
virtual QDomElement asGml3( QDomDocument &doc, int precision = 17, const QString &ns = "gml", QgsAbstractGeometry::AxisOrder axisOrder = QgsAbstractGeometry::AxisOrder::XY ) const;
2017-04-27 07:55:22 +02:00
virtual QString asJson( int precision = 17 ) const;
2015-05-15 15:41:56 +02:00
virtual QgsRectangle boundingBox() const;
2015-05-15 15:41:56 +02:00
2017-04-27 07:55:22 +02:00
virtual QgsCoordinateSequence coordinateSequence() const;
virtual int nCoordinates() const;
2015-05-15 15:41:56 +02:00
virtual double closestSegment( const QgsPoint &pt, QgsPoint &segmentPt /Out/, QgsVertexId &vertexAfter /Out/, int *leftOf /Out/ = 0, double epsilon = 4 * DBL_EPSILON ) const;
virtual bool nextVertex( QgsVertexId &id, QgsPoint &vertex /Out/ ) const;
2017-04-27 07:55:22 +02:00
virtual bool insertVertex( QgsVertexId position, const QgsPoint &vertex );
virtual bool moveVertex( QgsVertexId position, const QgsPoint &newPos );
virtual bool deleteVertex( QgsVertexId position );
2015-05-15 15:41:56 +02:00
2015-05-15 15:41:56 +02:00
virtual double length() const;
2015-05-15 15:41:56 +02:00
virtual double area() const;
virtual double perimeter() const;
2015-05-29 17:59:52 +02:00
2017-04-27 07:55:22 +02:00
virtual bool hasCurvedSegments() const;
2016-01-28 10:30:06 +01:00
2017-04-27 07:55:22 +02:00
virtual QgsAbstractGeometry *segmentize( double tolerance = M_PI_2 / 90, SegmentationToleranceType toleranceType = MaximumAngle ) const /Factory/;
%Docstring
2017-12-15 10:36:55 -04:00
Returns a geometry without curves. Caller takes ownership
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param tolerance: segmentation tolerance
:param toleranceType: maximum segmentation angle or maximum difference between approximation and curve*
2017-04-27 07:55:22 +02:00
%End
virtual double vertexAngle( QgsVertexId vertex ) const;
virtual double segmentLength( QgsVertexId startVertex ) const;
2016-01-28 10:30:06 +01:00
virtual int vertexCount( int part = 0, int ring = 0 ) const;
2016-01-28 10:30:06 +01:00
virtual int ringCount( int part = 0 ) const;
virtual int partCount() const;
virtual QgsPoint vertexAt( QgsVertexId id ) const;
virtual bool addZValue( double zValue = 0 );
virtual bool addMValue( double mValue = 0 );
virtual bool dropZValue();
virtual bool dropMValue();
virtual void swapXy();
virtual QgsGeometryCollection *toCurveType() const /Factory/;
virtual QgsGeometryCollection *createEmptyWithSameType() const /Factory/;
protected:
virtual int childCount() const;
virtual QgsAbstractGeometry *childGeometry( int index ) const;
protected:
virtual bool wktOmitChildType() const;
2017-04-27 07:55:22 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Returns whether child type names are omitted from Wkt representations of the collection
2017-04-27 07:55:22 +02:00
.. versionadded:: 2.12
%End
bool fromCollectionWkt( const QString &wkt, const QVector<QgsAbstractGeometry *> &subtypes, const QString &defaultChildWkbType = QString() );
2017-04-27 07:55:22 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Reads a collection from a WKT string.
2017-04-27 07:55:22 +02:00
%End
virtual QgsRectangle calculateBoundingBox() const;
virtual void clearCache() const;
2015-05-15 15:41:56 +02:00
};
2017-04-27 07:55:22 +02:00
2017-09-25 14:20:39 +10:00
2017-04-27 07:55:22 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/geometry/qgsgeometrycollection.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/