QGIS/python/core/auto_generated/qgsvectorlayereditutils.sip.in

265 lines
9.5 KiB
Plaintext
Raw Normal View History

2017-05-23 09:45:57 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgsvectorlayereditutils.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsVectorLayerEditUtils
{
2017-05-23 09:45:57 +02:00
%TypeHeaderCode
2017-05-23 09:45:57 +02:00
#include "qgsvectorlayereditutils.h"
%End
public:
QgsVectorLayerEditUtils( QgsVectorLayer *layer );
bool insertVertex( double x, double y, QgsFeatureId atFeatureId, int beforeVertex );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Insert a new vertex before the given vertex number,
in the given ring, item (first number is index 0), and feature
Not meaningful for Point geometries
2017-05-23 09:45:57 +02:00
%End
bool insertVertex( const QgsPoint &point, QgsFeatureId atFeatureId, int beforeVertex );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Inserts a new vertex before the given vertex number,
in the given ring, item (first number is index 0), and feature
Not meaningful for Point geometries
2017-05-23 09:45:57 +02:00
%End
2017-01-11 09:51:38 +03:00
bool moveVertex( double x, double y, QgsFeatureId atFeatureId, int atVertex );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Moves the vertex at the given position number,
ring and item (first number is index 0), and feature
to the given coordinates
2017-05-23 09:45:57 +02:00
%End
bool moveVertex( const QgsPoint &p, QgsFeatureId atFeatureId, int atVertex ) /PyName=moveVertexV2/;
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Moves the vertex at the given position number,
ring and item (first number is index 0), and feature
to the given coordinates
2017-05-23 09:45:57 +02:00
.. note::
available in Python bindings as moveVertexV2
%End
2016-02-14 03:50:23 +01:00
QgsVectorLayer::EditResult deleteVertex( QgsFeatureId featureId, int vertex );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Deletes a vertex from a feature.
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param featureId: ID of feature to remove vertex from
:param vertex: index of vertex to delete
2017-05-23 09:45:57 +02:00
.. versionadded:: 2.14
%End
QgsGeometry::OperationResult addRing( const QVector<QgsPointXY> &ring, const QgsFeatureIds &targetFeatureIds = QgsFeatureIds(), QgsFeatureId *modifiedFeatureId = 0 ) /Deprecated/;
%Docstring
Adds a ring to polygon/multipolygon features
:param ring: ring to add
:param targetFeatureIds: if specified, only these features will be the candidates for adding a ring. Otherwise
all intersecting features are tested and the ring is added to the first valid feature.
:param modifiedFeatureId: if specified, feature ID for feature that ring was added to will be stored in this parameter
:return: OperationResult result code: success or reason of failure
.. deprecated:: QGIS 3.12
- will be removed in QGIS 4.0. Use the variant which accepts QgsPoint objects instead of QgsPointXY.
2017-05-23 09:45:57 +02:00
%End
QgsGeometry::OperationResult addRing( const QgsPointSequence &ring, const QgsFeatureIds &targetFeatureIds = QgsFeatureIds(), QgsFeatureId *modifiedFeatureId = 0 );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds a ring to polygon/multipolygon features
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param ring: ring to add
:param targetFeatureIds: if specified, only these features will be the candidates for adding a ring. Otherwise
all intersecting features are tested and the ring is added to the first valid feature.
2017-12-15 10:36:55 -04:00
:param modifiedFeatureId: if specified, feature ID for feature that ring was added to will be stored in this parameter
:return: OperationResult result code: success or reason of failure
2017-05-23 09:45:57 +02:00
%End
QgsGeometry::OperationResult addRing( QgsCurve *ring, const QgsFeatureIds &targetFeatureIds = QgsFeatureIds(), QgsFeatureId *modifiedFeatureId = 0 ) /PyName=addCurvedRing/;
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds a ring to polygon/multipolygon features
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param ring: ring to add
:param targetFeatureIds: if specified, only these features will be the candidates for adding a ring. Otherwise
all intersecting features are tested and the ring is added to the first valid feature.
2017-12-15 10:36:55 -04:00
:param modifiedFeatureId: if specified, feature ID for feature that ring was added to will be stored in this parameter
:return: OperationResult result code: success or reason of failure
.. note::
available in python bindings as addCurvedRing
2017-05-23 09:45:57 +02:00
%End
2016-02-14 03:50:23 +01:00
QgsGeometry::OperationResult addPart( const QVector<QgsPointXY> &ring, QgsFeatureId featureId ) /Deprecated/;
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds a new part polygon to a multipart feature
:return: - QgsGeometry.Success
- QgsGeometry.AddPartSelectedGeometryNotFound
- QgsGeometry.AddPartNotMultiGeometry
- QgsGeometry.InvalidBaseGeometry
- QgsGeometry.InvalidInput
.. deprecated:: QGIS 3.12
- will be removed in QGIS 4.0. Use the variant which accepts QgsPoint objects instead of QgsPointXY.
2017-05-23 09:45:57 +02:00
%End
QgsGeometry::OperationResult addPart( const QgsPointSequence &ring, QgsFeatureId featureId );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds a new part polygon to a multipart feature
:return: - QgsGeometry.Success
- QgsGeometry.AddPartSelectedGeometryNotFound
- QgsGeometry.AddPartNotMultiGeometry
- QgsGeometry.InvalidBaseGeometry
- QgsGeometry.InvalidInput
2017-12-15 10:36:55 -04:00
.. note::
available in python bindings as addPartV2
2017-05-23 09:45:57 +02:00
%End
QgsGeometry::OperationResult addPart( QgsCurve *ring, QgsFeatureId featureId ) /PyName=addCurvedPart/;
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds a new part polygon to a multipart feature
2017-08-14 10:35:56 +02:00
:return: - QgsGeometry.Success
- QgsGeometry.AddPartSelectedGeometryNotFound
- QgsGeometry.AddPartNotMultiGeometry
- QgsGeometry.InvalidBaseGeometry
- QgsGeometry.InvalidInput
2017-08-14 10:35:56 +02:00
.. note::
available in python bindings as addCurvedPart
2017-05-23 09:45:57 +02:00
%End
2016-02-14 03:50:23 +01:00
int translateFeature( QgsFeatureId featureId, double dx, double dy );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Translates feature by dx, dy
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param featureId: id of the feature to translate
:param dx: translation of x-coordinate
:param dy: translation of y-coordinate
:return: 0 in case of success
%End
QgsGeometry::OperationResult splitParts( const QVector<QgsPointXY> &splitLine, bool topologicalEditing = false ) /Deprecated/;
%Docstring
Splits parts cut by the given line
:param splitLine: line that splits the layer feature parts
:param topologicalEditing: ``True`` if topological editing is enabled
:return: - QgsGeometry.InvalidBaseGeometry
- QgsGeometry.Success
- QgsGeometry.InvalidInput
- QgsGeometry.NothingHappened if a selection is present but no feature has been split
- QgsGeometry.InvalidBaseGeometry
- QgsGeometry.GeometryEngineError
- QgsGeometry.SplitCannotSplitPoint
.. deprecated:: QGIS 3.12
- will be removed in QGIS 4.0. Use the variant which accepts QgsPoint objects instead of QgsPointXY.
2017-05-23 09:45:57 +02:00
%End
QgsGeometry::OperationResult splitParts( const QgsPointSequence &splitLine, bool topologicalEditing = false );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Splits parts cut by the given line
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param splitLine: line that splits the layer feature parts
2019-02-26 19:54:09 +10:00
:param topologicalEditing: ``True`` if topological editing is enabled
2017-12-15 10:36:55 -04:00
:return: - QgsGeometry.InvalidBaseGeometry
- QgsGeometry.Success
- QgsGeometry.InvalidInput
- QgsGeometry.NothingHappened if a selection is present but no feature has been split
- QgsGeometry.InvalidBaseGeometry
- QgsGeometry.GeometryEngineError
- QgsGeometry.SplitCannotSplitPoint
2017-05-23 09:45:57 +02:00
%End
2014-01-27 09:22:24 +01:00
2019-10-01 10:44:54 +02:00
QgsGeometry::OperationResult splitFeatures( const QVector<QgsPointXY> &splitLine, bool topologicalEditing = false ) /Deprecated/;
%Docstring
Splits features cut by the given line
:param splitLine: line that splits the layer features
:param topologicalEditing: ``True`` if topological editing is enabled
:return: 0 in case of success,
4 if there is a selection but no feature split
.. deprecated:: QGIS 3.12
- will be removed in QGIS 4.0. Use the variant which accepts QgsPoint objects instead of QgsPointXY.
%End
QgsGeometry::OperationResult splitFeatures( const QgsPointSequence &splitLine, bool topologicalEditing = false );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Splits features cut by the given line
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:param splitLine: line that splits the layer features
2019-02-26 19:54:09 +10:00
:param topologicalEditing: ``True`` if topological editing is enabled
2017-12-15 10:36:55 -04:00
:return: 0 in case of success,
4 if there is a selection but no feature split
2017-05-23 09:45:57 +02:00
%End
int addTopologicalPoints( const QgsGeometry &geom );
2017-05-23 09:45:57 +02:00
%Docstring
2017-12-15 10:36:55 -04:00
Adds topological points for every vertex of the geometry.
2017-12-15 21:36:08 -04:00
:param geom: the geometry where each vertex is added to segments of other features
2017-12-15 10:36:55 -04:00
2017-12-16 10:38:54 -04:00
:return: 0 in case of success
2017-05-23 09:45:57 +02:00
.. note::
geom is not going to be modified by the function
%End
int addTopologicalPoints( const QgsPointXY &p );
2017-05-23 09:45:57 +02:00
%Docstring
2019-08-06 09:22:00 +02:00
Adds a vertex to segments which intersect point ``p`` but don't
2017-12-15 10:36:55 -04:00
already have a vertex there. If a feature already has a vertex at position p,
no additional vertex is inserted. This method is useful for topological
editing.
2017-12-15 21:36:08 -04:00
2017-12-15 10:36:55 -04:00
:return: 0 in case of success
%End
int addTopologicalPoints( const QgsPoint &p );
%Docstring
2019-08-06 09:22:00 +02:00
Adds a vertex to segments which intersect point ``p`` but don't
already have a vertex there. If a feature already has a vertex at position p,
no additional vertex is inserted. This method is useful for topological
editing.
:return: 0 in case of success
.. versionadded:: 3.10
2017-05-23 09:45:57 +02:00
%End
};
2017-05-23 09:45:57 +02:00
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgsvectorlayereditutils.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/