QGIS API Documentation
3.26.3-Buenos Aires (65e4edfdad)
|
Go to the documentation of this file.
25 const QString expr = mFilters[layer->
id()];
26 if ( !expr.isEmpty() )
41 result->mFilters = mFilters;
47 mFilters[layer->
id()] = filter.
dump();
QString dump() const
Returns an expression string, constructed from the internal abstract syntax tree.
QStringList layerAttributes(const QgsVectorLayer *layer, const QStringList &attributes) const override
Returns the list of visible attribute names from a list of attributes names for the given layer.
void filterFeatures(const QgsVectorLayer *layer, QgsFeatureRequest &filterFeatures) const override
Filter the features of the layer.
void setFilter(const QgsVectorLayer *layer, const QgsExpression &expression)
Set a filter for the given layer.
This class wraps a request for features to a vector layer (or directly its vector data provider).
QgsFeatureFilter()=default
Constructor.
QString id() const
Returns the layer's unique ID, which is used to access this layer from QgsProject.
Represents a vector layer which manages a vector based data sets.
Abstract interface for use by classes that filter the features or attributes of a layer.
QgsFeatureFilterProvider * clone() const override
Returns a clone of the object.
Class for parsing and evaluation of expressions (formerly called "search strings")....