Skip to content

Commit

Permalink
docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed Oct 15, 2018
1 parent 56d299e commit 71dbd5a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/app/qgsgeometryvalidationservice.cpp
Expand Up @@ -24,13 +24,10 @@ email : matthias@opengis.ch
QgsGeometryValidationService::QgsGeometryValidationService( QgsProject *project )
{
connect( project, &QgsProject::layersAdded, this, &QgsGeometryValidationService::onLayersAdded );

mIsValidGeometryCheck = new QgsIsValidGeometryCheck();
}

QgsGeometryValidationService::~QgsGeometryValidationService()
{
delete mIsValidGeometryCheck;
}

bool QgsGeometryValidationService::validationActive( QgsVectorLayer *layer, QgsFeatureId feature ) const
Expand Down
9 changes: 9 additions & 0 deletions src/app/qgsgeometryvalidationservice.h
Expand Up @@ -27,6 +27,11 @@ class QgsVectorLayer;
// TODO: Should be retrieved from registry!!
class QgsIsValidGeometryCheck;


/**
* This service connects to all layers in a project and triggers validation
* of features whenever they are edited.
*/
class QgsGeometryValidationService : public QObject
{
Q_OBJECT
Expand All @@ -49,6 +54,10 @@ class QgsGeometryValidationService : public QObject
QgsGeometryValidationService( QgsProject *project );
~QgsGeometryValidationService();

/**
* Returns if a validation is active for the specified \a feature on
* \a layer.
*/
bool validationActive( QgsVectorLayer *layer, QgsFeatureId feature ) const;

signals:
Expand Down

0 comments on commit 71dbd5a

Please sign in to comment.