Skip to content

Commit 525a3da

Browse files
committedDec 22, 2018
More doxygen
1 parent c8be505 commit 525a3da

12 files changed

+49
-17
lines changed
 

‎python/analysis/auto_generated/vector/geometry_checker/qgsfeaturepool.sip.in

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,16 @@ A feature pool is based on a vector layer and caches features.
2727
#include "qgsfeaturepool.h"
2828
%End
2929
public:
30+
3031
QgsFeaturePool( QgsVectorLayer *layer );
32+
%Docstring
33+
Creates a new feature pool for ``layer``.
34+
%End
3135
virtual ~QgsFeaturePool();
3236

3337
bool getFeature( QgsFeatureId id, QgsFeature &feature, QgsFeedback *feedback = 0 );
3438
%Docstring
35-
Retrieve the feature with the specified ``id`` into ``feature``.
39+
Retrieves the feature with the specified ``id`` into ``feature``.
3640
It will be retrieved from the cache or from the underlying layer if unavailable.
3741
If the feature is neither available from the cache nor from the layer it will return false.
3842
If ``feedback`` is specified, the call may return if the feedback is canceled.
@@ -55,7 +59,7 @@ Implementations will remove the feature from the layer or from the data provider
5559

5660
QgsVectorLayer *layer() const;
5761
%Docstring
58-
Get a pointer to the underlying layer.
62+
Gets a pointer to the underlying layer.
5963
May return a ``None`` if the layer has been deleted.
6064
This must only be called from the main thread.
6165
%End

‎python/analysis/auto_generated/vector/geometry_checker/qgsgeometrycheckerutils.sip.in

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,11 @@ Returns the geometry of this feature.
6262
If useMapCrs was specified, it will already be reprojected into the
6363
CRS specified in the context specified in the constructor.
6464
%End
65+
6566
QString id() const;
67+
%Docstring
68+
Returns a combination of the layerId and the feature id.
69+
%End
6670
bool operator==( const QgsGeometryCheckerUtils::LayerFeature &other ) const;
6771
bool operator!=( const QgsGeometryCheckerUtils::LayerFeature &other ) const;
6872

‎python/analysis/auto_generated/vector/geometry_checker/qgsgeometrycheckfactory.sip.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ A factory for geometry checks.
3434

3535
virtual QgsGeometryCheck *createGeometryCheck( const QgsGeometryCheckContext *context, const QVariantMap &configuration ) const = 0 /Factory/;
3636
%Docstring
37-
Create a new geometry check with ``context`` and ``configuration``.
37+
Creates a new geometry check with ``context`` and ``configuration``.
3838
%End
3939

4040
virtual QString id() const = 0;

‎python/analysis/auto_generated/vector/geometry_checker/qgsgeometrycheckregistry.sip.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,14 +50,14 @@ Ownership is transferred to the caller.
5050

5151
QList<QgsGeometryCheckFactory *> geometryCheckFactories( QgsVectorLayer *layer, QgsGeometryCheck::CheckType type, QgsGeometryCheck::Flags flags = 0 ) const;
5252
%Docstring
53-
Get all geometry check factories that are compatible with ``layer`` and have all of the ``flags`` set.
53+
Returns all geometry check factories that are compatible with ``layer`` and have all of the ``flags`` set.
5454

5555
.. versionadded:: 3.4
5656
%End
5757

5858
void registerGeometryCheck( QgsGeometryCheckFactory *checkFactory /Transfer/ );
5959
%Docstring
60-
Register a new geometry check factory.
60+
Registers a new geometry check factory.
6161

6262
.. versionadded:: 3.4
6363
%End

‎src/analysis/vector/geometry_checker/qgsfeaturepool.h

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,19 +39,23 @@ class ANALYSIS_EXPORT QgsFeaturePool : public QgsFeatureSink SIP_ABSTRACT
3939
{
4040

4141
public:
42+
43+
/**
44+
* Creates a new feature pool for \a layer.
45+
*/
4246
QgsFeaturePool( QgsVectorLayer *layer );
4347
virtual ~QgsFeaturePool() = default;
4448

4549
/**
46-
* Retrieve the feature with the specified \a id into \a feature.
50+
* Retrieves the feature with the specified \a id into \a feature.
4751
* It will be retrieved from the cache or from the underlying layer if unavailable.
4852
* If the feature is neither available from the cache nor from the layer it will return false.
4953
* If \a feedback is specified, the call may return if the feedback is canceled.
5054
*/
5155
bool getFeature( QgsFeatureId id, QgsFeature &feature, QgsFeedback *feedback = nullptr );
5256

5357
/**
54-
* Get features for the provided \a request. No features will be fetched
58+
* Gets features for the provided \a request. No features will be fetched
5559
* from the cache and the request is sent directly to the underlying feature source.
5660
* Results of the request are cached in the pool and the ids of all the features
5761
* are returned. This can be used to warm the cache for a particular area of interest
@@ -81,22 +85,22 @@ class ANALYSIS_EXPORT QgsFeaturePool : public QgsFeatureSink SIP_ABSTRACT
8185
QgsFeatureIds allFeatureIds() const SIP_SKIP;
8286

8387
/**
84-
* Get all feature ids in the bounding box \a rect. It will use a spatial index to
88+
* Gets all feature ids in the bounding box \a rect. It will use a spatial index to
8589
* determine the ids.
8690
*
8791
* \note not available in Python bindings
8892
*/
8993
QgsFeatureIds getIntersects( const QgsRectangle &rect ) const SIP_SKIP;
9094

9195
/**
92-
* Get a pointer to the underlying layer.
96+
* Gets a pointer to the underlying layer.
9397
* May return a ``nullptr`` if the layer has been deleted.
9498
* This must only be called from the main thread.
9599
*/
96100
QgsVectorLayer *layer() const;
97101

98102
/**
99-
* Get a QPointer to the underlying layer.
103+
* Gets a QPointer to the underlying layer.
100104
* Note that access to any methods of the object
101105
* will need to be done on the main thread and
102106
* the pointer will need to be checked for validity
@@ -142,7 +146,7 @@ class ANALYSIS_EXPORT QgsFeaturePool : public QgsFeatureSink SIP_ABSTRACT
142146
void removeFeature( const QgsFeatureId featureId );
143147

144148
/**
145-
* Set all the feature ids governed by this feature pool.
149+
* Sets all the feature ids governed by this feature pool.
146150
* Should be called by subclasses constructor and whenever
147151
* they insert a new feature.
148152
*

‎src/analysis/vector/geometry_checker/qgsgeometrycheckerutils.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,10 @@ class ANALYSIS_EXPORT QgsGeometryCheckerUtils
7474
* CRS specified in the context specified in the constructor.
7575
*/
7676
const QgsGeometry &geometry() const;
77+
78+
/**
79+
* Returns a combination of the layerId and the feature id.
80+
*/
7781
QString id() const;
7882
bool operator==( const QgsGeometryCheckerUtils::LayerFeature &other ) const;
7983
bool operator!=( const QgsGeometryCheckerUtils::LayerFeature &other ) const;

‎src/analysis/vector/geometry_checker/qgsgeometrycheckfactory.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ class ANALYSIS_EXPORT QgsGeometryCheckFactory SIP_ABSTRACT
5252
virtual ~QgsGeometryCheckFactory() = default;
5353

5454
/**
55-
* Create a new geometry check with \a context and \a configuration.
55+
* Creates a new geometry check with \a context and \a configuration.
5656
*/
5757
virtual QgsGeometryCheck *createGeometryCheck( const QgsGeometryCheckContext *context, const QVariantMap &configuration ) const = 0 SIP_FACTORY;
5858

‎src/analysis/vector/geometry_checker/qgsgeometrycheckregistry.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,14 @@ class ANALYSIS_EXPORT QgsGeometryCheckRegistry
6565
QgsGeometryCheck *geometryCheck( const QString &checkId, QgsGeometryCheckContext *context, const QVariantMap &geometryCheckConfig ) SIP_FACTORY;
6666

6767
/**
68-
* Get all geometry check factories that are compatible with \a layer and have all of the \a flags set.
68+
* Returns all geometry check factories that are compatible with \a layer and have all of the \a flags set.
6969
*
7070
* \since QGIS 3.4
7171
*/
7272
QList<QgsGeometryCheckFactory *> geometryCheckFactories( QgsVectorLayer *layer, QgsGeometryCheck::CheckType type, QgsGeometryCheck::Flags flags = nullptr ) const;
7373

7474
/**
75-
* Register a new geometry check factory.
75+
* Registers a new geometry check factory.
7676
*
7777
* \since QGIS 3.4
7878
*/

‎src/analysis/vector/geometry_checker/qgsgeometrymissingvertexcheck.h

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,20 @@ class ANALYSIS_EXPORT QgsGeometryMissingVertexCheck : public QgsGeometryCheck
3737
Q_GADGET
3838

3939
public:
40+
41+
/**
42+
* The available resolutions for missing vertex check.
43+
*/
4044
enum ResolutionMethod
4145
{
42-
NoChange,
43-
AddMissingVertex
46+
NoChange, //!< Do nothing
47+
AddMissingVertex //! Add the missing vertex
4448
};
4549
Q_ENUM( ResolutionMethod )
4650

51+
/**
52+
* Creates a new missing vertex geometry check with \a context and the provided \a geometryCheckConfiguration.
53+
*/
4754
explicit QgsGeometryMissingVertexCheck( const QgsGeometryCheckContext *context, const QVariantMap &geometryCheckConfiguration );
4855
void collectErrors( const QMap<QString, QgsFeaturePool *> &featurePools, QList<QgsGeometryCheckError *> &errors, QStringList &messages, QgsFeedback *feedback, const LayerFeatureIds &ids = LayerFeatureIds() ) const override;
4956
void fixError( const QMap<QString, QgsFeaturePool *> &featurePools, QgsGeometryCheckError *error, int method, const QMap<QString, int> &mergeAttributeIndices, Changes &changes ) const override;

‎src/analysis/vector/geometry_checker/qgsvectordataproviderfeaturepool.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ email : matthias@opengis.ch
3030
class ANALYSIS_EXPORT QgsVectorDataProviderFeaturePool : public QgsFeaturePool
3131
{
3232
public:
33+
34+
/**
35+
* Creates a new feature pool for the data provider of \a layer.
36+
* If \a selectedOnly is set to true, only selected features will be managed by the pool.
37+
*/
3338
QgsVectorDataProviderFeaturePool( QgsVectorLayer *layer, bool selectedOnly = false );
3439

3540
bool addFeature( QgsFeature &feature, QgsFeatureSink::Flags flags = nullptr ) override;

‎src/analysis/vector/geometry_checker/qgsvectorlayerfeaturepool.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ class ANALYSIS_EXPORT QgsVectorLayerFeaturePool : public QObject, public QgsFeat
3232
Q_OBJECT
3333

3434
public:
35+
36+
/**
37+
* Creates a new feature pool for \a layer.
38+
*/
3539
QgsVectorLayerFeaturePool( QgsVectorLayer *layer );
3640

3741
bool addFeature( QgsFeature &feature, QgsFeatureSink::Flags flags = nullptr ) override;

‎tests/code_layout/acceptable_missing_doc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,7 @@
483483
"QgsGeometryChecker": [],
484484
"QgsGeometryFollowBoundariesCheck": ["factoryDescription()", "factoryId()", "factoryCompatibleGeometryTypes()", "factoryIsCompatible(QgsVectorLayer *layer)", "ResolutionMethod", "factoryCheckType()", "QgsGeometryFollowBoundariesCheck(QgsGeometryCheckContext *context, const QVariantMap &configuration, QgsVectorLayer *checkLayer)"],
485485
"QgsGeometryMultipartCheck": ["factoryDescription()", "factoryId()", "factoryCompatibleGeometryTypes()", "factoryIsCompatible(QgsVectorLayer *layer)", "ResolutionMethod", "factoryCheckType()", "QgsGeometryMultipartCheck(QgsGeometryCheckContext *context, const QVariantMap &configuration)"],
486-
"QgsGeometrySelfIntersectionCheckError": [],
486+
"QgsGeometrySelfIntersectionCheckError": ["QgsGeometrySelfIntersectionCheckError(const QgsSingleGeometryCheck *check, const QgsGeometry &geometry, const QgsGeometry &errorLocation, QgsVertexId vertexId, const QgsGeometryUtils::SelfIntersection &intersection)", "intersection() const"],
487487
"QgsGeometryGapCheckError": ["QgsGeometrySelfIntersectionCheckError(const QgsSingleGeometryCheck *check, const QgsGeometry &geometry, const QgsGeometry &errorLocation, QgsVertexId vertexId, const QgsGeometryUtils::SelfIntersection &intersection)", "intersection() const"],
488488
"QgsGeometryPointCoveredByLineCheck": ["factoryDescription()", "factoryId()", "factoryCompatibleGeometryTypes()", "factoryIsCompatible(QgsVectorLayer *layer)", "ResolutionMethod", "factoryCheckType()", "QgsGeometryPointCoveredByLineCheck(QgsGeometryCheckContext *context, const QVariantMap &configuration)"],
489489
"QgsGeometrySelfIntersectionCheck": ["QgsGeometrySelfIntersectionCheck(const QgsGeometryCheckContext *context, const QVariantMap &configuration=QVariantMap())", "ResolutionMethod"],

0 commit comments

Comments
 (0)
Please sign in to comment.