16 #ifndef QGS_GEOMETRY_CHECK_H
17 #define QGS_GEOMETRY_CHECK_H
19 #include <QApplication>
21 #include <QStringList>
24 #include "qgis_analysis.h"
112 QMap<QString, QgsFeatureIds>
toMap()
const
119 return ids.isEmpty();
166 AvailableInValidation = 1 << 1
168 Q_DECLARE_FLAGS( Flags, Flag )
207 return what == other.
what && type == other.
type && vidx == other.
vidx;
212 return !( *
this == other );
220 typedef QMap<QString, QMap<QgsFeatureId, QList<QgsGeometryCheck::Change> > >
Changes;
244 return mConfiguration.value( name,
QgsSettings().value(
"/geometry_checker/" +
id() +
"/" + name, defaultValue ) ).value<T>();
261 virtual QList<QgsWkbTypes::GeometryType> compatibleGeometryTypes()
const = 0;
266 virtual QgsGeometryCheck::Flags flags()
const;
285 virtual void fixError(
const QMap<QString, QgsFeaturePool *> &featurePools,
QgsGeometryCheckError *error,
int method,
const QMap<QString, int> &mergeAttributeIndices, Changes &changes
SIP_INOUT )
const SIP_SKIP;
292 virtual QList<QgsGeometryCheckResolutionMethod> availableResolutionMethods()
const;
301 Q_DECL_DEPRECATED
virtual QStringList resolutionMethods() const
SIP_DEPRECATED;
308 virtual QString description() const = 0;
315 virtual QString
id() const = 0;
322 virtual CheckType checkType() const = 0;
339 QMap<QString, QgsFeatureIds> allLayerFeatureIds(
const QMap<QString, QgsFeaturePool *> &featurePools )
const SIP_SKIP;
347 void replaceFeatureGeometryPart(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx,
QgsAbstractGeometry *newPartGeom, Changes &changes )
const SIP_SKIP;
355 void deleteFeatureGeometryPart(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx, Changes &changes )
const SIP_SKIP;
363 void deleteFeatureGeometryRing(
const QMap<QString, QgsFeaturePool *> &featurePools,
const QString &layerId,
QgsFeature &feature,
int partIdx,
int ringIdx, Changes &changes )
const SIP_SKIP;
374 double scaleFactor(
const QPointer<QgsVectorLayer> &layer )
const SIP_SKIP;
377 #endif // QGS_GEOMETRY_CHECK_H