QGIS API Documentation 3.99.0-Master (a26b91b364d)
|
Abstract interface for use by classes that filter the features or attributes of a layer. More...
#include <qgsfeaturefilterprovider.h>
Public Member Functions | |
QgsFeatureFilterProvider ()=default | |
virtual | ~QgsFeatureFilterProvider ()=default |
virtual QgsFeatureFilterProvider * | clone () const =0 |
Create a clone of the feature filter provider. | |
virtual Q_DECL_DEPRECATED void | filterFeatures (const QgsVectorLayer *layer, QgsFeatureRequest &featureRequest) const |
Add additional filters to the feature request to further restrict the features returned by the request. | |
virtual void | filterFeatures (const QString &layerId, QgsFeatureRequest &featureRequest) const |
Add additional filters to the feature request to further restrict the features returned by the request. | |
virtual Q_DECL_DEPRECATED bool | isFilterThreadSafe () const |
Returns true if the filterFeature function is thread safe, which will lead to reliance on layer ID instead of the raw layer pointer. | |
virtual QStringList | layerAttributes (const QgsVectorLayer *layer, const QStringList &attributes) const =0 |
Returns the list of visible attribute names from a list of attributes names for the given layer. | |
Abstract interface for use by classes that filter the features or attributes of a layer.
A QgsFeatureFilterProvider provides a method for modifying a QgsFeatureRequest in place to apply additional filters to the request, since QGIS 3.18 a method to filter allowed attributes is also available.
Definition at line 41 of file qgsfeaturefilterprovider.h.
|
default |
|
virtualdefault |
|
pure virtual |
Create a clone of the feature filter provider.
Implemented in QgsFeatureExpressionFilterProvider, QgsGroupedFeatureFilterProvider, QgsAccessControl, QgsDimensionFilter, QgsFeatureFilter, and QgsFeatureFilterProviderGroup.
|
inlinevirtual |
Add additional filters to the feature request to further restrict the features returned by the request.
Derived classes must implement this method.
layer | the layer to filter |
featureRequest | the feature request to update |
Reimplemented in QgsFeatureExpressionFilterProvider, QgsGroupedFeatureFilterProvider, QgsAccessControl, QgsDimensionFilter, QgsFeatureFilter, and QgsFeatureFilterProviderGroup.
Definition at line 68 of file qgsfeaturefilterprovider.h.
|
inlinevirtual |
Add additional filters to the feature request to further restrict the features returned by the request.
Derived classes must implement this method.
layerId | the layer ID to filter |
featureRequest | the feature request to update |
Reimplemented in QgsFeatureExpressionFilterProvider, and QgsGroupedFeatureFilterProvider.
Definition at line 81 of file qgsfeaturefilterprovider.h.
|
inlinevirtual |
Returns true
if the filterFeature function is thread safe, which will lead to reliance on layer ID instead of the raw layer pointer.
Reimplemented in QgsGroupedFeatureFilterProvider, QgsAccessControl, QgsDimensionFilter, QgsFeatureFilter, and QgsFeatureFilterProviderGroup.
Definition at line 59 of file qgsfeaturefilterprovider.h.
|
pure virtual |
Returns the list of visible attribute names from a list of attributes names for the given layer.
Implemented in QgsFeatureExpressionFilterProvider, QgsGroupedFeatureFilterProvider, QgsAccessControl, QgsDimensionFilter, QgsFeatureFilter, and QgsFeatureFilterProviderGroup.