16#ifndef QGSVECTORLAYERUTILS_H
17#define QGSVECTORLAYERUTILS_H
67 QList<QgsVectorLayer *> layers()
const;
76 QMap<QgsVectorLayer *, QgsFeatureIds> mDuplicatedFeatures;
136 static QList< QVariant > getValues(
const QgsVectorLayer *layer,
const QString &fieldOrExpression,
bool &ok,
bool selectedOnly =
false,
QgsFeedback *feedback =
nullptr );
150 static QList< double > getDoubleValues(
const QgsVectorLayer *layer,
const QString &fieldOrExpression,
bool &ok,
bool selectedOnly =
false,
int *nullCount =
nullptr,
QgsFeedback *feedback =
nullptr );
165 static QVariant createUniqueValue(
const QgsVectorLayer *layer,
int fieldIndex,
const QVariant &seed = QVariant() );
173 static QVariant createUniqueValueFromCache(
const QgsVectorLayer *layer,
int fieldIndex,
const QSet<QVariant> &existingValues,
const QVariant &seed = QVariant() );
181 static bool attributeHasConstraints(
const QgsVectorLayer *layer,
int attributeIndex );
242 static std::unique_ptr<QgsVectorLayerFeatureSource> getFeatureSource( QPointer<QgsVectorLayer> layer,
QgsFeedback *feedback =
nullptr )
SIP_SKIP;
330 static
bool fieldIsReadOnly( const
QgsVectorLayer *layer,
int fieldIndex );
341 static
bool fieldEditabilityDependsOnFeature( const
QgsVectorLayer *layer,
int fieldIndex );
375 IgnoreAuxiliaryLayers = 1 << 1,
429 static QString guessFriendlyIdentifierField(
const QgsFields &fields,
bool *foundFriendly
SIP_OUT =
nullptr )
SIP_PYNAME( guessFriendlyIdentifierFieldV2 );
449 static QString guessFriendlyIdentifierField(
const QgsFields &fields );
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
Wrapper for iterator of features from vector data provider or vector layer.
Abstract base class for all 2D vector feature renderers.
An interface for objects which accept features via addFeature(s) methods.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
Base class for feedback objects to be used for cancellation of something running in a worker thread.
ConstraintStrength
Strength of constraints.
@ ConstraintStrengthNotSet
Constraint is not set.
ConstraintOrigin
Origin of constraints.
@ ConstraintOriginNotSet
Constraint is not set.
Container of fields for a vector layer.
A geometry is the spatial representation of a feature.
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
We may need stable references to symbol layers, when pointers to symbol layers are not usable (when a...
Abstract base class for symbol layers.
Contains mainly the QMap with QgsVectorLayer and QgsFeatureIds which list all the duplicated features...
QgsDuplicateFeatureContext()=default
Encapsulate geometry and attributes for new features, to be passed to createFeatures.
Contains utility methods for working with QgsVectorLayers.
QList< QgsVectorLayerUtils::QgsFeatureData > QgsFeaturesDataList
Alias for list of QgsFeatureData.
QFlags< CascadedFeatureFlag > CascadedFeatureFlags
CascadedFeatureFlag
Flags that can be used when determining cascaded features.
Represents a vector layer which manages a vector based dataset.
#define SIP_ENUM_BASETYPE(type)
QMap< int, QVariant > QgsAttributeMap
QList< QgsFeature > QgsFeatureList
QSet< QgsFeatureId > QgsFeatureIds
QHash< QString, QgsMaskedLayer > QgsMaskedLayers
masked layers where key is the layer id
QSet< QString > symbolLayerIds