16 #ifndef QGS_GEOMETRY_CHECK_H
17 #define QGS_GEOMETRY_CHECK_H
19 #include <QApplication>
21 #include <QStringList>
24 #include "qgis_analysis.h"
113 QMap<QString, QgsFeatureIds>
toMap()
const
120 return ids.isEmpty();
167 AvailableInValidation = 1 << 1
169 Q_DECLARE_FLAGS( Flags, Flag )
206 return what == other.
what && type == other.
type && vidx == other.
vidx;
214 typedef QMap<QString, QMap<QgsFeatureId, QList<QgsGeometryCheck::Change> > >
Changes;
238 return mConfiguration.value( name,
QgsSettings().value(
"/geometry_checker/" +
id() +
"/" + name, defaultValue ) ).value<T>();
255 virtual QList<QgsWkbTypes::GeometryType> compatibleGeometryTypes()
const = 0;
260 virtual QgsGeometryCheck::Flags flags()
const;
279 virtual void fixError(
const QMap<QString, QgsFeaturePool *> &featurePools,
QgsGeometryCheckError *error,
int method,
const QMap<QString, int> &mergeAttributeIndices, Changes &changes
SIP_INOUT )
const SIP_SKIP;
286 virtual QList<QgsGeometryCheckResolutionMethod> availableResolutionMethods()
const;
295 Q_DECL_DEPRECATED
virtual QStringList resolutionMethods() const
SIP_DEPRECATED;
302 virtual QString description() const = 0;
309 virtual QString
id() const = 0;
316 virtual CheckType checkType() const = 0;
333 QMap<QString, QgsFeatureIds> allLayerFeatureIds(
const QMap<QString, QgsFeaturePool *> &featurePools )
const SIP_SKIP;
341 void replaceFeatureGeometryPart(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx,
QgsAbstractGeometry *newPartGeom, Changes &changes )
const SIP_SKIP;
349 void deleteFeatureGeometryPart(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx, Changes &changes )
const SIP_SKIP;
357 void deleteFeatureGeometryRing(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx,
int ringIdx, Changes &changes )
const SIP_SKIP;
368 double scaleFactor(
const QPointer<QgsVectorLayer> &layer )
const SIP_SKIP;
371 #endif // QGS_GEOMETRY_CHECK_H