38using namespace Qt::StringLiterals;
46 if ( !mLayer->isSpatial() )
57 mLayer->changeGeometry( atFeatureId, geometry );
63 if ( !mLayer->isSpatial() )
74 mLayer->changeGeometry( atFeatureId, geometry );
86 if ( !mLayer->isSpatial() )
112 return mLayer->changeGeometry( atFeatureId, geometry );
122 if ( !mLayer->isSpatial() )
137 geometry.
set(
nullptr );
140 mLayer->changeGeometry( featureId, geometry );
156 if ( !ring->isClosed() )
170 if ( !targetFeatureIds.isEmpty() )
183 bool success =
false;
194 addRingReturnCode = g.
addRing(
static_cast< QgsCurve *
>( ring->clone() ) );
198 addRingReturnCode = g.
addRing(
static_cast< QgsCurve *
>( ring->reversed() ) );
204 if ( modifiedFeatureIds )
206 modifiedFeatureIds->insert( f.
id() );
219double QgsVectorLayerEditUtils::getTopologicalSearchRadius(
const QgsVectorLayer *layer )
239void QgsVectorLayerEditUtils::addTopologicalPointsToLayers(
const QgsGeometry &geom,
QgsVectorLayer *vlayer,
const QList<QgsMapLayer *> &layers,
const QString &toolName )
244 for ( QgsMapLayer *layer : layers )
246 QgsVectorLayer *vectorLayer = qobject_cast<QgsVectorLayer *>( layer );
251 QgsCoordinateTransform ct;
252 if ( vectorLayer->
crs() != vlayer->
crs() )
259 catch ( QgsCsException & )
261 QgsDebugError( u
"Bounding box transformation failed, skipping topological points for layer %1"_s.arg( vlayer->
id() ) );
265 bbox.
grow( getTopologicalSearchRadius( vectorLayer ) );
272 vectorLayer->
beginEditCommand( QObject::tr(
"Topological points added by '%1'" ).arg( toolName ) );
275 if ( vectorLayer->
crs() != vlayer->
crs() )
280 QgsGeometry transformedGeom( geom );
281 transformedGeom.transform( ct );
284 catch ( QgsCsException & )
286 QgsDebugError( u
"transformation to vectorLayer coordinate failed"_s );
294 if ( returnValue == 0 )
311 for ( QVector<QgsPointXY>::const_iterator it = ring.constBegin(); it != ring.constEnd(); ++it )
315 return addRing( l, targetFeatureIds, modifiedFeatureId );
321 return addRing( ringLine, targetFeatureIds, modifiedFeatureId );
326 std::unique_ptr<QgsCurve> uniquePtrRing( ring );
327 if ( modifiedFeatureId )
331 if ( modifiedFeatureId && !modifiedFeatureIds.empty() )
332 *modifiedFeatureId = *modifiedFeatureIds.begin();
335 return staticAddRing( mLayer, uniquePtrRing, targetFeatureIds,
nullptr,
true );
340 std::unique_ptr<QgsCurve> uniquePtrRing( ring );
341 return staticAddRing( mLayer, uniquePtrRing, targetFeatureIds, modifiedFeatureIds,
false );
348 for ( QVector<QgsPointXY>::const_iterator it = points.constBegin(); it != points.constEnd(); ++it )
352 return addPart( l, featureId );
357 if ( !mLayer->isSpatial() )
361 bool firstPart =
false;
363 if ( !mLayer->getFeatures(
QgsFeatureRequest().setFilterFid( featureId ).setNoAttributes() ).nextFeature( f ) )
379 if ( firstPart &&
QgsWkbTypes::isSingleType( mLayer->wkbType() ) && mLayer->dataProvider()->doesStrictFeatureTypeCheck() )
384 mLayer->changeGeometry( featureId, geometry );
391 std::unique_ptr<QgsCurve> uniquePtrRing( ring );
393 if ( !mLayer->isSpatial() )
397 bool firstPart =
false;
399 if ( !mLayer->getFeatures(
QgsFeatureRequest().setFilterFid( featureId ).setNoAttributes() ).nextFeature( f ) )
412 uniquePtrRing.reset( uniquePtrRing->reversed() );
419 if ( firstPart &&
QgsWkbTypes::isSingleType( mLayer->wkbType() ) && mLayer->dataProvider()->doesStrictFeatureTypeCheck() )
424 mLayer->changeGeometry( featureId, geometry );
431 std::unique_ptr<QgsCurvePolygon> uniquePtrPoly( polygon );
433 if ( !mLayer->isSpatial() )
440 bool firstPart =
false;
442 if ( !mLayer->getFeatures(
QgsFeatureRequest().setFilterFid( featureId ).setNoAttributes() ).nextFeature( f ) )
469 if ( firstPart &&
QgsWkbTypes::isSingleType( mLayer->wkbType() ) && mLayer->dataProvider()->doesStrictFeatureTypeCheck() )
474 mLayer->changeGeometry( featureId, geometry );
482 if ( !mLayer->isSpatial() )
494 mLayer->changeGeometry( featureId, geometry );
502 for ( QVector<QgsPointXY>::const_iterator it = splitLine.constBegin(); it != splitLine.constEnd(); ++it )
513 bool preserveCircular =
false;
514 return splitFeatures( &lineString, topologyTestPoints, preserveCircular, topologicalEditing );
519 if ( !mLayer->isSpatial() )
525 int numberOfSplitFeatures = 0;
528 const QgsFeatureIds selectedIds = mLayer->selectedFeatureIds();
530 if ( !selectedIds.isEmpty() )
532 features = mLayer->getSelectedFeatures();
546 else if ( bBox.
height() == 0.0 && bBox.
width() > 0 )
554 double bufferDistance = 0.000001;
555 if ( mLayer->crs().isGeographic() )
556 bufferDistance = 0.00000001;
569 const int fieldCount = mLayer->fields().count();
579 QVector<QgsGeometry> newGeometries;
586 bool preserveCircularForGeom = preserveCircular;
587 preserveCircularForGeom &= ( splitCurveContainsCurves || featureGeom.
constGet()->hasCurvedSegments() );
588 splitFunctionReturn = featureGeom.
splitGeometry( curve, newGeometries, preserveCircularForGeom, topologicalEditing, featureTopologyTestPoints );
590 topologyTestPoints.append( featureTopologyTestPoints );
595 double featureGeomSize = size( featureGeom );
597 QVector<QgsGeometry>::iterator largestNewFeature = std::max_element( newGeometries.begin(), newGeometries.end(), [&size](
const QgsGeometry &a,
const QgsGeometry &b ) ->
bool {
598 return size( a ) < size( b );
601 if ( size( *largestNewFeature ) > featureGeomSize )
604 *largestNewFeature = featureGeom;
609 mLayer->changeGeometry( feat.
id(), featureGeom );
613 for (
int fieldIdx = 0; fieldIdx < fieldCount; ++fieldIdx )
615 const QgsField field = mLayer->fields().at( fieldIdx );
627 const double originalValue = feat.
attribute( fieldIdx ).toDouble();
629 double originalSize = 0;
631 switch ( originalGeom.
type() )
639 originalSize = originalGeom.
length();
642 originalSize = originalGeom.
area();
647 switch ( featureGeom.
type() )
655 newSize = featureGeom.
length();
658 newSize = featureGeom.
area();
662 attributeMap.insert( fieldIdx, originalSize > 0 ? ( originalValue * newSize / originalSize ) : originalValue );
669 if ( !attributeMap.isEmpty() )
671 mLayer->changeAttributeValues( feat.
id(), attributeMap );
675 for (
const QgsGeometry &geom : std::as_const( newGeometries ) )
678 for (
int fieldIdx = 0; fieldIdx < fieldCount; ++fieldIdx )
680 const QgsField field = mLayer->fields().at( fieldIdx );
689 attributeMap.insert( fieldIdx, feat.
attribute( fieldIdx ) );
696 attributeMap.insert( fieldIdx, feat.
attribute( fieldIdx ) );
700 const double originalValue = feat.
attribute( fieldIdx ).toDouble();
702 double originalSize = 0;
704 switch ( originalGeom.
type() )
712 originalSize = originalGeom.
length();
715 originalSize = originalGeom.
area();
720 switch ( geom.
type() )
731 newSize = geom.
area();
735 attributeMap.insert( fieldIdx, originalSize > 0 ? ( originalValue * newSize / originalSize ) : originalValue );
749 if ( topologicalEditing )
751 QgsPointSequence::const_iterator topol_it = featureTopologyTestPoints.constBegin();
752 for ( ; topol_it != featureTopologyTestPoints.constEnd(); ++topol_it )
757 ++numberOfSplitFeatures;
761 returnCode = splitFunctionReturn;
765 if ( !featuresDataToAdd.isEmpty() )
770 mLayer->addFeatures( featuresListToAdd );
773 if ( numberOfSplitFeatures == 0 )
784 for ( QVector<QgsPointXY>::const_iterator it = splitLine.constBegin(); it != splitLine.constEnd(); ++it )
793 if ( !mLayer->isSpatial() )
796 double xMin, yMin, xMax, yMax;
798 int numberOfSplitParts = 0;
802 if ( mLayer->selectedFeatureCount() > 0 )
804 fit = mLayer->getSelectedFeatures();
808 if ( boundingBoxFromPointList( splitLine, xMin, yMin, xMax, yMax ) )
828 else if ( bBox.
height() == 0.0 && bBox.
width() > 0 )
836 double bufferDistance = 0.000001;
837 if ( mLayer->crs().isGeographic() )
838 bufferDistance = 0.00000001;
855 QVector<QgsGeometry> resultCollection;
859 QVector<QgsGeometry> newGeometries;
862 const Qgis::GeometryOperationResult splitFunctionReturn = part.splitGeometry( splitLine, newGeometries, topologicalEditing, partTopologyTestPoints,
false );
866 for (
int i = 0; i < newGeometries.size(); ++i )
868 resultCollection.append( newGeometries.at( i ).asGeometryCollection() );
871 topologyTestPoints.append( partTopologyTestPoints );
873 ++numberOfSplitParts;
880 resultCollection.append( part );
884 return splitFunctionReturn;
889 mLayer->changeGeometry( feat.
id(), newGeom );
891 if ( topologicalEditing )
893 QgsPointSequence::const_iterator topol_it = topologyTestPoints.constBegin();
894 for ( ; topol_it != topologyTestPoints.constEnd(); ++topol_it )
900 if ( numberOfSplitParts == 0 && mLayer->selectedFeatureCount() > 0 )
913 if ( !mLayer->isSpatial() )
921 bool pointsAdded =
false;
933 return pointsAdded ? 0 : 2;
938 if ( !mLayer->isSpatial() )
941 double segmentSearchEpsilon = mLayer->crs().isGeographic() ? 1e-12 : 1e-8;
944 double threshold = getTopologicalSearchRadius( mLayer );
947 searchRect.
grow( threshold );
952 bool pointsAdded =
false;
959 mLayer->changeGeometry( f.
id(), geom );
963 return pointsAdded ? 0 : 2;
968 if ( !mLayer->isSpatial() )
976 bool pointsAdded =
false;
978 QgsPointSequence::const_iterator it = ps.constBegin();
979 while ( it != ps.constEnd() )
988 return pointsAdded ? 0 : 2;
1000 errorMessage.clear();
1002 if ( mergeFeatureIds.isEmpty() )
1004 errorMessage = QObject::tr(
"List of features to merge is empty" );
1009 for (
int i = 0; i < mergeAttributes.count(); ++i )
1011 QVariant val = mergeAttributes.at( i );
1014 && mLayer->dataProvider()
1015 && mLayer->dataProvider()->defaultValueClause( mLayer->fields().fieldOriginIndex( i ) ) == val;
1018 QString errorMessageConvertCompatible;
1019 if ( !isDefaultValue && !mLayer->fields().at( i ).convertCompatible( val, &errorMessageConvertCompatible ) )
1021 if ( errorMessage.isEmpty() )
1022 errorMessage = QObject::tr(
"Could not store value '%1' in field of type %2: %3" ).arg( mergeAttributes.at( i ).toString(), mLayer->fields().at( i ).typeName(), errorMessageConvertCompatible );
1024 newAttributes[i] = val;
1027 mLayer->beginEditCommand( QObject::tr(
"Merged features" ) );
1030 QgsFeatureIds::const_iterator feature_it = mergeFeatureIds.constBegin();
1031 for ( ; feature_it != mergeFeatureIds.constEnd(); ++feature_it )
1033 if ( *feature_it != targetFeatureId )
1034 mLayer->deleteFeature( *feature_it );
1042 mLayer->addFeature( mergeFeature );
1046 mLayer->changeGeometry( targetFeatureId, mergeGeometry );
1047 mLayer->changeAttributeValues( targetFeatureId, newAttributes );
1050 mLayer->endEditCommand();
1052 mLayer->triggerRepaint();
1057bool QgsVectorLayerEditUtils::boundingBoxFromPointList(
const QgsPointSequence &list,
double &xmin,
double &ymin,
double &xmax,
double &ymax )
const
1064 xmin = std::numeric_limits<double>::max();
1065 xmax = -std::numeric_limits<double>::max();
1066 ymin = std::numeric_limits<double>::max();
1067 ymax = -std::numeric_limits<double>::max();
1069 for ( QgsPointSequence::const_iterator it = list.constBegin(); it != list.constEnd(); ++it )
1071 if ( it->x() < xmin )
1075 if ( it->x() > xmax )
1079 if ( it->y() < ymin )
1083 if ( it->y() > ymax )
@ NoOrientation
Unknown orientation or sentinel value.
@ CounterClockwise
Counter-clockwise direction.
@ Clockwise
Clockwise direction.
GeometryOperationResult
Success or failure of a geometry operation.
@ AddPartSelectedGeometryNotFound
The selected geometry cannot be found.
@ InvalidInputGeometryType
The input geometry (ring, part, split line, etc.) has not the correct geometry type.
@ Success
Operation succeeded.
@ AddRingNotInExistingFeature
The input ring doesn't have any existing ring to fit into.
@ AddRingNotClosed
The input ring is not closed.
@ NothingHappened
Nothing happened, without any error.
@ InvalidBaseGeometry
The base geometry on which the operation is done is invalid or empty.
@ LayerNotEditable
Cannot edit layer.
@ ExactIntersect
Use exact geometry intersection (slower) instead of bounding boxes.
@ NoGeometry
Geometry is not required. It may still be returned if e.g. required for a filter condition.
@ GeometryRatio
New values are computed by the ratio of their area/length compared to the area/length of the original...
@ UnsetField
Clears the field value so that the data provider backend will populate using any backend triggers or ...
@ DefaultValue
Use default field value.
@ Duplicate
Duplicate original value.
@ Provider
Field originates from the underlying data provider of the vector layer.
VectorEditResult
Specifies the result of a vector layer edit operation.
@ EmptyGeometry
Edit operation resulted in an empty geometry.
@ Success
Edit operation was successful.
@ FetchFeatureFailed
Unable to fetch requested feature.
@ EditFailed
Edit operation failed.
@ InvalidLayer
Edit failed due to invalid layer.
The vertex_iterator class provides an STL-style iterator for vertices.
virtual bool addZValue(double zValue=0)=0
Adds a z-dimension to the geometry, initialized to a preset value.
bool isMeasure() const
Returns true if the geometry contains m values.
virtual QgsRectangle boundingBox() const
Returns the minimal bounding box for the geometry.
bool is3D() const
Returns true if the geometry is 3D and contains a z-value.
virtual int nCoordinates() const
Returns the number of nodes contained in the geometry.
virtual bool addMValue(double mValue=0)=0
Adds a measure to the geometry, initialized to a preset value.
virtual bool hasCurvedSegments() const
Returns true if the geometry contains curved segments.
Qgis::DistanceUnit mapUnits
Curve polygon geometry type.
void forceCounterClockwise()
Forces the polygon to respect the exterior ring is counter-clockwise, interior rings are clockwise co...
void forceClockwise()
Forces the polygon to respect the exterior ring is clockwise, interior rings are counter-clockwise co...
Abstract base class for curved geometry type.
Wrapper for iterator of features from vector data provider or vector layer.
bool nextFeature(QgsFeature &f)
Fetch next feature and stores in f, returns true on success.
Wraps a request for features to a vector layer (or directly its vector data provider).
QgsFeatureRequest & setFilterRect(const QgsRectangle &rectangle)
Sets the rectangle from which features will be taken.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
bool hasGeometry() const
Returns true if the feature has an associated geometry.
Q_INVOKABLE QVariant attribute(const QString &name) const
Lookup attribute value by attribute name.
Encapsulate a field in an attribute table or data source.
Qgis::FieldDomainSplitPolicy splitPolicy() const
Returns the field's split policy, which indicates how field values should be handled during a split o...
double geometryPrecision() const
The precision in which geometries on this layer should be saved.
A geometry is the spatial representation of a feature.
double length() const
Returns the planar, 2-dimensional length of geometry.
bool addTopologicalPoint(const QgsPoint &point, double snappingTolerance=1e-8, double segmentSearchEpsilon=1e-12)
Adds a vertex to the segment which intersect point but don't already have a vertex there.
static QgsGeometry collectGeometry(const QVector< QgsGeometry > &geometries)
Creates a new multipart geometry from a list of QgsGeometry objects.
QVector< QgsGeometry > asGeometryCollection() const
Returns contents of the geometry as a list of geometries.
QgsAbstractGeometry * get()
Returns a modifiable (non-const) reference to the underlying abstract geometry primitive.
const QgsAbstractGeometry * constGet() const
Returns a non-modifiable (const) reference to the underlying abstract geometry primitive.
bool insertVertex(double x, double y, int beforeVertex)
Insert a new vertex before the given vertex index, ring and item (first number is index 0) If the req...
bool convertToSingleType()
Converts multi type geometry into single type geometry e.g.
Qgis::GeometryOperationResult addRing(const QVector< QgsPointXY > &ring)
Adds a new ring to this geometry.
double area() const
Returns the planar, 2-dimensional area of the geometry.
Qgis::AngularDirection polygonOrientation() const
Returns the orientation of the polygon.
bool deleteVertices(const QSet< int > &atVertices)
Deletes vertices at the given positions (first number is index 0).
void set(QgsAbstractGeometry *geometry)
Sets the underlying geometry store.
QgsAbstractGeometry::vertex_iterator vertices_begin() const
Returns STL-style iterator pointing to the first vertex of the geometry.
QgsRectangle boundingBox() const
Returns the bounding box of the geometry.
Qgis::GeometryOperationResult addPartV2(const QVector< QgsPointXY > &points, Qgis::WkbType wkbType=Qgis::WkbType::Unknown)
Adds a new part to a the geometry.
Qgis::GeometryOperationResult translate(double dx, double dy, double dz=0.0, double dm=0.0)
Translates this geometry by dx, dy, dz and dm.
Q_DECL_DEPRECATED Qgis::GeometryOperationResult splitGeometry(const QVector< QgsPointXY > &splitLine, QVector< QgsGeometry > &newGeometries, bool topological, QVector< QgsPointXY > &topologyTestPoints, bool splitFeature=true)
Splits this geometry according to a given line.
bool moveVertex(double x, double y, int atVertex)
Moves the vertex at the given position number and item (first number is index 0) to the given coordin...
QgsAbstractGeometry::vertex_iterator vertices_end() const
Returns STL-style iterator pointing to the imaginary vertex after the last vertex of the geometry.
Line string geometry type, with support for z-dimension and m-values.
QgsCoordinateReferenceSystem crs
QgsCoordinateTransformContext transformContext() const
Returns the layer data provider coordinate transform context or a default transform context if the la...
Point geometry type, with support for z-dimension and m-values.
A rectangle specified with double values.
void setYMinimum(double y)
Set the minimum y value.
void setXMinimum(double x)
Set the minimum x value.
void setYMaximum(double y)
Set the maximum y value.
void setXMaximum(double x)
Set the maximum x value.
void grow(double delta)
Grows the rectangle in place by the specified amount.
static const QgsSettingsEntryDouble * settingsDigitizingDefaultMValue
Settings entry digitizing default m value.
static const QgsSettingsEntryDouble * settingsDigitizingDefaultZValue
Settings entry digitizing default z value.
Represents a default, "not-specified" value for a feature attribute.
int translateFeature(QgsFeatureId featureId, double dx, double dy)
Translates feature by dx, dy.
Qgis::VectorEditResult deleteVertices(QgsFeatureId featureId, const QSet< int > &vertices)
Deletes a set of vertices from a feature.
bool mergeFeatures(const QgsFeatureId &targetFeatureId, const QgsFeatureIds &mergeFeatureIds, const QgsAttributes &mergeAttributes, const QgsGeometry &unionGeometry, QString &errorMessage)
Merge features into a single one.
QgsVectorLayerEditUtils(QgsVectorLayer *layer)
bool insertVertex(double x, double y, QgsFeatureId atFeatureId, int beforeVertex)
Insert a new vertex before the given vertex number, in the given ring, item (first number is index 0)...
Q_DECL_DEPRECATED Qgis::GeometryOperationResult addPart(const QVector< QgsPointXY > &ring, QgsFeatureId featureId)
Adds a new part polygon to a multipart feature.
Qgis::VectorEditResult deleteVertex(QgsFeatureId featureId, int vertex)
Deletes a vertex from a feature.
Qgis::GeometryOperationResult addRingV2(QgsCurve *ring, const QgsFeatureIds &targetFeatureIds=QgsFeatureIds(), QgsFeatureIds *modifiedFeatureIds=nullptr)
Adds a ring to polygon/multipolygon features.
int addTopologicalPoints(const QgsGeometry &geom)
Adds topological points for every vertex of the geometry.
Q_DECL_DEPRECATED Qgis::GeometryOperationResult splitParts(const QVector< QgsPointXY > &splitLine, bool topologicalEditing=false)
Splits parts cut by the given line.
Q_DECL_DEPRECATED Qgis::GeometryOperationResult splitFeatures(const QVector< QgsPointXY > &splitLine, bool topologicalEditing=false)
Splits features cut by the given line.
bool moveVertex(double x, double y, QgsFeatureId atFeatureId, int atVertex)
Moves the vertex at the given position number, ring and item (first number is index 0),...
Q_DECL_DEPRECATED Qgis::GeometryOperationResult addRing(const QVector< QgsPointXY > &ring, const QgsFeatureIds &targetFeatureIds=QgsFeatureIds(), QgsFeatureId *modifiedFeatureId=nullptr)
Adds a ring to polygon/multipolygon features.
Encapsulate geometry and attributes for new features, to be passed to createFeatures.
QList< QgsVectorLayerUtils::QgsFeatureData > QgsFeaturesDataList
Alias for list of QgsFeatureData.
static QgsFeature createFeature(const QgsVectorLayer *layer, const QgsGeometry &geometry=QgsGeometry(), const QgsAttributeMap &attributes=QgsAttributeMap(), QgsExpressionContext *context=nullptr)
Creates a new feature ready for insertion into a layer.
static QgsFeatureList createFeatures(const QgsVectorLayer *layer, const QgsFeaturesDataList &featuresData, QgsExpressionContext *context=nullptr)
Creates a set of new features ready for insertion into a layer.
Represents a vector layer which manages a vector based dataset.
bool isEditable() const final
Returns true if the provider is in editing mode.
bool isSpatial() const final
Returns true if this is a geometry layer and false in case of NoGeometry (table only) or UnknownGeome...
void endEditCommand()
Finish edit command and add it to undo/redo stack.
void destroyEditCommand()
Destroy active command and reverts all changes in it.
QgsGeometryOptions * geometryOptions() const
Configuration and logic to apply automatically on any edit happening on this layer.
Q_INVOKABLE QgsVectorLayerEditBuffer * editBuffer()
Buffer with uncommitted editing operations. Only valid after editing has been turned on.
QgsFeatureIterator getFeatures(const QgsFeatureRequest &request=QgsFeatureRequest()) const final
Queries the layer for features specified in request.
Q_INVOKABLE Qgis::GeometryType geometryType() const
Returns point, line or polygon.
void beginEditCommand(const QString &text)
Create edit command for undo/redo operations.
int addTopologicalPoints(const QgsGeometry &geom)
Adds topological points for every vertex of the geometry.
QgsVectorDataProvider * dataProvider() final
Returns the layer's data provider, it may be nullptr.
bool changeGeometry(QgsFeatureId fid, QgsGeometry &geometry, bool skipDefaultValue=false)
Changes a feature's geometry within the layer's edit buffer (but does not immediately commit the chan...
static Q_INVOKABLE bool isSingleType(Qgis::WkbType type)
Returns true if the WKB type is a single type.
static Q_INVOKABLE bool hasZ(Qgis::WkbType type)
Tests whether a WKB type contains the z-dimension.
static Q_INVOKABLE bool hasM(Qgis::WkbType type)
Tests whether a WKB type contains m values.
bool qgsDoubleNear(double a, double b, double epsilon=4 *std::numeric_limits< double >::epsilon())
Compare two doubles (but allow some difference).
QVector< QgsPoint > QgsPointSequence
QMap< int, QVariant > QgsAttributeMap
QList< QgsFeature > QgsFeatureList
QSet< QgsFeatureId > QgsFeatureIds
qint64 QgsFeatureId
64 bit feature ids negative numbers are used for uncommitted/newly added features
#define QgsDebugError(str)