QGIS API Documentation 3.38.0-Grenoble (exported)
Loading...
Searching...
No Matches
qgsvectorlayer.h
Go to the documentation of this file.
1
2/***************************************************************************
3 -------------------
4 begin : Oct 29, 2003
5 copyright : (C) 2003 by Gary E.Sherman
6 email : sherman at mrcc.com
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17
18#ifndef QGSVECTORLAYER_H
19#define QGSVECTORLAYER_H
20
21#include "qgis_core.h"
22#include <QMap>
23#include <QSet>
24#include <QList>
25#include <QStringList>
26#include <QFont>
27#include <QMutex>
28
29#include "qgis.h"
30#include "qgsmaplayer.h"
31#include "qgsfeature.h"
32#include "qgsfeaturerequest.h"
33#include "qgsfeaturesource.h"
34#include "qgsfields.h"
37#include "qgseditformconfig.h"
40#include "qgsfeatureiterator.h"
46
47class QPainter;
48class QImage;
49
53class QgsCurve;
59class QgsGeometry;
60class QgsGeometryVertexIndex;
61class QgsMapToPixel;
62class QgsRectangle;
63class QgsRectangle;
64class QgsRelation;
65class QgsWeakRelation;
69class QgsSymbol;
76class QgsPoint;
77class QgsFeedback;
86
87#ifndef SIP_RUN
88template<class T>
90#endif
93
94
95typedef QList<int> QgsAttributeList;
96typedef QSet<int> QgsAttributeIds;
97
98// TODO QGIS4: Remove virtual from non-inherited methods (like isModified)
99
401{
402 Q_OBJECT
403
404 Q_PROPERTY( QString subsetString READ subsetString WRITE setSubsetString NOTIFY subsetStringChanged )
405 Q_PROPERTY( QString displayExpression READ displayExpression WRITE setDisplayExpression NOTIFY displayExpressionChanged )
406 Q_PROPERTY( QgsEditFormConfig editFormConfig READ editFormConfig WRITE setEditFormConfig NOTIFY editFormConfigChanged )
407 Q_PROPERTY( bool readOnly READ isReadOnly WRITE setReadOnly NOTIFY readOnlyChanged )
408 Q_PROPERTY( bool supportsEditing READ supportsEditing NOTIFY supportsEditingChanged )
409 Q_PROPERTY( QgsFields fields READ fields NOTIFY updatedFields )
410
411 public:
412
413 static const QgsSettingsEntryBool *settingsSimplifyLocal SIP_SKIP;
414
415 static const QgsSettingsEntryDouble *settingsSimplifyMaxScale SIP_SKIP;
416 static const QgsSettingsEntryDouble *settingsSimplifyDrawingTol SIP_SKIP;
417 static const QgsSettingsEntryEnumFlag<Qgis::VectorSimplificationAlgorithm> *settingsSimplifyAlgorithm SIP_SKIP;
418 static const QgsSettingsEntryEnumFlag<Qgis::VectorRenderingSimplificationFlags> *settingsSimplifyDrawingHints SIP_SKIP;
419
424 {
425
429 explicit LayerOptions( bool loadDefaultStyle = true,
430 bool readExtentFromXml = false )
431 : loadDefaultStyle( loadDefaultStyle )
432 , readExtentFromXml( readExtentFromXml )
433 {}
434
439 explicit LayerOptions( const QgsCoordinateTransformContext &transformContext,
440 bool loadDefaultStyle = true,
441 bool readExtentFromXml = false
442 )
443 : loadDefaultStyle( loadDefaultStyle )
444 , readExtentFromXml( readExtentFromXml )
445 , transformContext( transformContext )
446 {}
447
449 bool loadDefaultStyle = true;
450
455 bool readExtentFromXml = false;
456
462
475
488
502 bool skipCrsValidation = false;
503
515 bool forceReadOnly = false;
516
529 bool loadAllStoredStyles = false;
530 };
531
536 struct CORE_EXPORT DeleteContext
537 {
538
542 explicit DeleteContext( bool cascade = false, QgsProject *project = nullptr ): cascade( cascade ), project( project ) {}
543
550 QList<QgsVectorLayer *> handledLayers( bool includeAuxiliaryLayers = true ) const;
551
555 QgsFeatureIds handledFeatures( QgsVectorLayer *layer ) const;
556
557 QMap<QgsVectorLayer *, QgsFeatureIds> mHandledFeatures SIP_SKIP;
560 };
561
575 explicit QgsVectorLayer( const QString &path = QString(), const QString &baseName = QString(),
576 const QString &providerLib = "ogr", const QgsVectorLayer::LayerOptions &options = QgsVectorLayer::LayerOptions() );
577
578 ~QgsVectorLayer() override;
579
581 QgsVectorLayer( const QgsVectorLayer &rhs ) = delete;
583 QgsVectorLayer &operator=( QgsVectorLayer const &rhs ) = delete;
584
585#ifdef SIP_RUN
586 SIP_PYOBJECT __repr__();
587 % MethodCode
588 QString str = QStringLiteral( "<QgsVectorLayer: '%1' (%2)>" ).arg( sipCpp->name(), sipCpp->dataProvider() ? sipCpp->dataProvider()->name() : QStringLiteral( "Invalid" ) );
589 sipRes = PyUnicode_FromString( str.toUtf8().constData() );
590 % End
591#endif
592
600 QgsVectorLayer *clone() const override SIP_FACTORY;
601
606 QString storageType() const;
607
611 QString capabilitiesString() const;
612
613
623 bool isSqlQuery() const;
624
631 Qgis::VectorLayerTypeFlags vectorLayerTypeFlags() const;
632
633
637 QString dataComment() const;
638
646 QString displayField() const;
647
655 void setDisplayExpression( const QString &displayExpression );
656
663 QString displayExpression() const;
664
665 bool hasMapTips() const FINAL;
666
667 QgsVectorDataProvider *dataProvider() FINAL;
668 const QgsVectorDataProvider *dataProvider() const FINAL SIP_SKIP;
669 QgsMapLayerSelectionProperties *selectionProperties() override;
670 QgsMapLayerTemporalProperties *temporalProperties() override;
671 QgsMapLayerElevationProperties *elevationProperties() override;
672 QgsAbstractProfileGenerator *createProfileGenerator( const QgsProfileRequest &request ) override SIP_FACTORY;
673
684 void setProviderEncoding( const QString &encoding );
685
687 void setCoordinateSystem();
688
694 bool addJoin( const QgsVectorLayerJoinInfo &joinInfo );
695
700 bool removeJoin( const QString &joinLayerId );
701
705 QgsVectorLayerJoinBuffer *joinBuffer() { return mJoinBuffer; }
706
711 const QgsVectorLayerJoinBuffer *joinBuffer() const { return mJoinBuffer; } SIP_SKIP;
712
713 const QList<QgsVectorLayerJoinInfo> vectorJoins() const;
714
722 bool setDependencies( const QSet<QgsMapLayerDependency> &layers ) FINAL;
723
730 QSet<QgsMapLayerDependency> dependencies() const FINAL;
731
741 int addExpressionField( const QString &exp, const QgsField &fld );
742
749 void removeExpressionField( int index );
750
759 QString expressionField( int index ) const;
760
769 void updateExpressionField( int index, const QString &exp );
770
777 QgsActionManager *actions() { return mActions; }
778
784 const QgsActionManager *actions() const SIP_SKIP { return mActions; }
785
791 int selectedFeatureCount() const;
792
802 Q_INVOKABLE void selectByRect( QgsRectangle &rect, Qgis::SelectBehavior behavior = Qgis::SelectBehavior::SetSelection );
803
813 Q_INVOKABLE void selectByExpression( const QString &expression, Qgis::SelectBehavior behavior = Qgis::SelectBehavior::SetSelection, QgsExpressionContext *context = nullptr );
814
824 Q_INVOKABLE void selectByIds( const QgsFeatureIds &ids, Qgis::SelectBehavior behavior = Qgis::SelectBehavior::SetSelection );
825
837 Q_INVOKABLE void modifySelection( const QgsFeatureIds &selectIds, const QgsFeatureIds &deselectIds );
838
840 Q_INVOKABLE void invertSelection();
841
843 Q_INVOKABLE void selectAll();
844
852 Q_INVOKABLE void invertSelectionInRectangle( QgsRectangle &rect );
853
866 Q_INVOKABLE QgsFeatureList selectedFeatures() const;
867
883 QgsFeatureIterator getSelectedFeatures( QgsFeatureRequest request = QgsFeatureRequest() ) const;
884
892 Q_INVOKABLE const QgsFeatureIds &selectedFeatureIds() const;
893
895 Q_INVOKABLE QgsRectangle boundingBoxOfSelected() const;
896
903 bool labelsEnabled() const;
904
914 void setLabelsEnabled( bool enabled );
915
920 bool diagramsEnabled() const;
921
923 void setDiagramRenderer( QgsDiagramRenderer *r SIP_TRANSFER );
924 const QgsDiagramRenderer *diagramRenderer() const { return mDiagramRenderer; }
925
926 void setDiagramLayerSettings( const QgsDiagramLayerSettings &s );
927 const QgsDiagramLayerSettings *diagramLayerSettings() const { return mDiagramLayerSettings; }
928
935 QgsFeatureRenderer *renderer() { return mRenderer; }
936
944 const QgsFeatureRenderer *renderer() const SIP_SKIP { return mRenderer; }
945
952 void setRenderer( QgsFeatureRenderer *r SIP_TRANSFER );
953
963 void addFeatureRendererGenerator( QgsFeatureRendererGenerator *generator SIP_TRANSFER );
964
974 void removeFeatureRendererGenerator( const QString &id );
975
983 QList< const QgsFeatureRendererGenerator * > featureRendererGenerators() const;
984
986 Q_INVOKABLE Qgis::GeometryType geometryType() const;
987
989 Q_INVOKABLE Qgis::WkbType wkbType() const FINAL;
990
991 QgsCoordinateReferenceSystem sourceCrs() const FINAL;
992 QString sourceName() const FINAL;
993
998 bool readXml( const QDomNode &layer_node, QgsReadWriteContext &context ) FINAL;
999
1004 bool writeXml( QDomNode &layer_node, QDomDocument &doc, const QgsReadWriteContext &context ) const FINAL;
1005
1006 QString encodedSource( const QString &source, const QgsReadWriteContext &context ) const FINAL;
1007 QString decodedSource( const QString &source, const QString &provider, const QgsReadWriteContext &context ) const FINAL;
1008
1012 void resolveReferences( QgsProject *project ) FINAL;
1013
1026 bool loadAuxiliaryLayer( const QgsAuxiliaryStorage &storage, const QString &key = QString() );
1027
1036 void setAuxiliaryLayer( QgsAuxiliaryLayer *layer SIP_TRANSFER = nullptr );
1037
1042 QgsAuxiliaryLayer *auxiliaryLayer();
1043
1048 const QgsAuxiliaryLayer *auxiliaryLayer() const SIP_SKIP;
1049
1050 bool readSymbology( const QDomNode &layerNode, QString &errorMessage,
1051 QgsReadWriteContext &context, QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories ) FINAL;
1052 bool readStyle( const QDomNode &node, QString &errorMessage,
1053 QgsReadWriteContext &context, QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories ) FINAL;
1054 bool writeSymbology( QDomNode &node, QDomDocument &doc, QString &errorMessage,
1055 const QgsReadWriteContext &context, QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories ) const FINAL;
1056 bool writeStyle( QDomNode &node, QDomDocument &doc, QString &errorMessage,
1057 const QgsReadWriteContext &context, QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories ) const FINAL;
1058
1067 bool writeSld( QDomNode &node, QDomDocument &doc, QString &errorMessage, const QVariantMap &props = QVariantMap() ) const;
1068
1069 bool readSld( const QDomNode &node, QString &errorMessage ) FINAL;
1070
1076 long long featureCount( const QString &legendKey ) const;
1077
1084 QgsFeatureIds symbolFeatureIds( const QString &legendKey ) const;
1085
1096 Qgis::FeatureAvailability hasFeatures() const FINAL;
1097
1098 QString loadDefaultStyle( bool &resultFlag SIP_OUT ) FINAL;
1099
1112 QgsVectorLayerFeatureCounter *countSymbolFeatures( bool storeSymbolFids = false );
1113
1121 virtual bool setSubsetString( const QString &subset );
1122
1127 virtual QString subsetString() const;
1128
1134 QgsFeatureIterator getFeatures( const QgsFeatureRequest &request = QgsFeatureRequest() ) const FINAL;
1135
1139 inline QgsFeatureIterator getFeatures( const QString &expression )
1140 {
1141 return getFeatures( QgsFeatureRequest( expression ) );
1142 }
1143
1148 Q_INVOKABLE inline QgsFeature getFeature( QgsFeatureId fid ) const
1149 {
1150 QgsFeature feature;
1151 getFeatures( QgsFeatureRequest( fid ) ).nextFeature( feature );
1152 return feature;
1153 }
1154
1159 QgsGeometry getGeometry( QgsFeatureId fid ) const;
1160
1165 {
1166 return getFeatures( QgsFeatureRequest( fids ) );
1167 }
1168
1173 {
1174 return getFeatures( QgsFeatureRequest( rectangle ) );
1175 }
1176
1178
1204 bool updateFeature( QgsFeature &feature, bool skipDefaultValues = false );
1205
1217 bool insertVertex( double x, double y, QgsFeatureId atFeatureId, int beforeVertex );
1218
1230 bool insertVertex( const QgsPoint &point, QgsFeatureId atFeatureId, int beforeVertex );
1231
1242 bool moveVertex( double x, double y, QgsFeatureId atFeatureId, int atVertex );
1243
1254 bool moveVertex( const QgsPoint &p, QgsFeatureId atFeatureId, int atVertex ) SIP_PYNAME( moveVertexV2 );
1255
1265 Qgis::VectorEditResult deleteVertex( QgsFeatureId featureId, int vertex );
1266
1274 Q_INVOKABLE bool deleteSelectedFeatures( int *deletedCount = nullptr, QgsVectorLayer::DeleteContext *context = nullptr );
1275
1296 Q_DECL_DEPRECATED Qgis::GeometryOperationResult addRing( const QVector<QgsPointXY> &ring, QgsFeatureId *featureId = nullptr ) SIP_DEPRECATED;
1297
1298
1318 Q_INVOKABLE Qgis::GeometryOperationResult addRing( const QgsPointSequence &ring, QgsFeatureId *featureId = nullptr );
1319
1340 Q_INVOKABLE Qgis::GeometryOperationResult addRing( QgsCurve *ring SIP_TRANSFER, QgsFeatureId *featureId = nullptr ) SIP_PYNAME( addCurvedRing );
1341
1361 Q_DECL_DEPRECATED Qgis::GeometryOperationResult addPart( const QList<QgsPointXY> &ring ) SIP_DEPRECATED;
1362
1363#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
1364
1385 Q_DECL_DEPRECATED Qgis::GeometryOperationResult addPart( const QVector<QgsPointXY> &ring ) SIP_PYNAME( addPartV2 ) SIP_DEPRECATED;
1386#endif
1387
1407 Q_INVOKABLE Qgis::GeometryOperationResult addPart( const QgsPointSequence &ring ) SIP_PYNAME( addPartV2 );
1408
1416 Q_INVOKABLE Qgis::GeometryOperationResult addPart( QgsCurve *ring SIP_TRANSFER ) SIP_PYNAME( addCurvedPart );
1417
1429 Q_INVOKABLE int translateFeature( QgsFeatureId featureId, double dx, double dy );
1430
1451 Q_DECL_DEPRECATED Qgis::GeometryOperationResult splitParts( const QVector<QgsPointXY> &splitLine, bool topologicalEditing = false ) SIP_DEPRECATED;
1452
1472 Q_INVOKABLE Qgis::GeometryOperationResult splitParts( const QgsPointSequence &splitLine, bool topologicalEditing = false );
1473
1494 Q_DECL_DEPRECATED Qgis::GeometryOperationResult splitFeatures( const QVector<QgsPointXY> &splitLine, bool topologicalEditing = false ) SIP_DEPRECATED;
1495
1515 Q_INVOKABLE Qgis::GeometryOperationResult splitFeatures( const QgsPointSequence &splitLine, bool topologicalEditing = false );
1516
1539 Q_INVOKABLE Qgis::GeometryOperationResult splitFeatures( const QgsCurve *curve, QgsPointSequence &topologyTestPoints SIP_OUT, bool preserveCircular = false, bool topologicalEditing = false );
1540
1554 int addTopologicalPoints( const QgsGeometry &geom );
1555
1572 Q_DECL_DEPRECATED int addTopologicalPoints( const QgsPointXY &p ) SIP_DEPRECATED;
1573
1590 int addTopologicalPoints( const QgsPoint &p );
1591
1608 int addTopologicalPoints( const QgsPointSequence &ps );
1609
1615 const QgsAbstractVectorLayerLabeling *labeling() const SIP_SKIP { return mLabeling; }
1616
1623
1627 void setLabeling( QgsAbstractVectorLayerLabeling *labeling SIP_TRANSFER );
1628
1630 bool isEditable() const FINAL;
1631
1633 bool isSpatial() const FINAL;
1634
1636 bool isModified() const override;
1637
1643 bool isAuxiliaryField( int index, int &srcIndex ) const;
1644
1646 void reload() FINAL;
1647
1651 QgsMapLayerRenderer *createMapRenderer( QgsRenderContext &rendererContext ) FINAL SIP_FACTORY;
1652
1653 QgsRectangle extent() const FINAL;
1654 QgsRectangle sourceExtent() const FINAL;
1655
1656 QgsBox3D extent3D() const FINAL;
1657 QgsBox3D sourceExtent3D() const FINAL;
1658
1665 QgsFields fields() const FINAL;
1666
1670 Q_INVOKABLE inline QgsAttributeList attributeList() const { return mFields.allAttributesList(); }
1671
1675 QgsAttributeList primaryKeyAttributes() const;
1676
1682 long long featureCount() const FINAL;
1683
1690 bool setReadOnly( bool readonly = true );
1691
1697 bool supportsEditing() const override;
1698
1719 bool changeGeometry( QgsFeatureId fid, QgsGeometry &geometry, bool skipDefaultValue = false );
1720
1753 Q_INVOKABLE bool changeAttributeValue( QgsFeatureId fid, int field, const QVariant &newValue, const QVariant &oldValue = QVariant(), bool skipDefaultValues = false, QgsVectorLayerToolsContext *context = nullptr );
1754
1791 Q_INVOKABLE bool changeAttributeValues( QgsFeatureId fid, const QgsAttributeMap &newValues, const QgsAttributeMap &oldValues = QgsAttributeMap(), bool skipDefaultValues = false, QgsVectorLayerToolsContext *context = nullptr );
1792
1802 bool addAttribute( const QgsField &field );
1803
1808 void setFieldAlias( int index, const QString &aliasString );
1809
1814 void removeFieldAlias( int index );
1815
1825 bool renameAttribute( int index, const QString &newName );
1826
1833 QString attributeAlias( int index ) const;
1834
1836 QString attributeDisplayName( int index ) const;
1837
1839 QgsStringMap attributeAliases() const;
1840
1841#ifndef SIP_RUN
1842
1848 void setFieldSplitPolicy( int index, Qgis::FieldDomainSplitPolicy policy );
1849
1855 void setFieldDuplicatePolicy( int index, Qgis::FieldDuplicatePolicy policy );
1856#else
1857
1864 void setFieldSplitPolicy( int index, Qgis::FieldDomainSplitPolicy policy );
1865
1866 % MethodCode
1867 if ( a0 < 0 || a0 >= sipCpp->fields().count() )
1868 {
1869 PyErr_SetString( PyExc_KeyError, QByteArray::number( a0 ) );
1870 sipIsErr = 1;
1871 }
1872 else
1873 {
1874 sipCpp->setFieldSplitPolicy( a0, a1 );
1875 }
1876 % End
1877
1884 void setFieldDuplicatePolicy( int index, Qgis::FieldDuplicatePolicy policy );
1885
1886 % MethodCode
1887 if ( a0 < 0 || a0 >= sipCpp->fields().count() )
1888 {
1889 PyErr_SetString( PyExc_KeyError, QByteArray::number( a0 ) );
1890 sipIsErr = 1;
1891 }
1892 else
1893 {
1894 sipCpp->setFieldDuplicatePolicy( a0, a1 );
1895 }
1896 % End
1897#endif
1898
1903 Q_DECL_DEPRECATED QSet<QString> excludeAttributesWms() const SIP_DEPRECATED;
1904
1909 Q_DECL_DEPRECATED void setExcludeAttributesWms( const QSet<QString> &att ) SIP_DEPRECATED;
1910
1915 Q_DECL_DEPRECATED QSet<QString> excludeAttributesWfs() const SIP_DEPRECATED;
1916
1921 Q_DECL_DEPRECATED void setExcludeAttributesWfs( const QSet<QString> &att ) SIP_DEPRECATED;
1922
1931 virtual bool deleteAttribute( int attr );
1932
1940 bool deleteAttributes( const QList<int> &attrs );
1941
1942 bool addFeatures( QgsFeatureList &features, QgsFeatureSink::Flags flags = QgsFeatureSink::Flags() ) FINAL;
1943
1954 Q_INVOKABLE bool deleteFeature( QgsFeatureId fid, QgsVectorLayer::DeleteContext *context = nullptr );
1955
1969 Q_INVOKABLE bool deleteFeatures( const QgsFeatureIds &fids, QgsVectorLayer::DeleteContext *context = nullptr );
1970
1994 Q_INVOKABLE bool commitChanges( bool stopEditing = true );
1995
2001 QStringList commitErrors() const;
2002
2012 Q_INVOKABLE bool rollBack( bool deleteBuffer = true );
2013
2020 QList<QgsRelation> referencingRelations( int idx ) const;
2021
2031 QList<QgsWeakRelation> weakRelations() const SIP_SKIP;
2032
2041 void setWeakRelations( const QList< QgsWeakRelation > &relations ) SIP_SKIP;
2042
2044 Q_INVOKABLE QgsVectorLayerEditBuffer *editBuffer() { return mEditBuffer; }
2045
2050 const QgsVectorLayerEditBuffer *editBuffer() const SIP_SKIP { return mEditBuffer; }
2051
2056 void beginEditCommand( const QString &text );
2057
2059 void endEditCommand();
2060
2062 void destroyEditCommand();
2063
2068 Q_DECL_DEPRECATED static void drawVertexMarker( double x, double y, QPainter &p, Qgis::VertexMarkerType type, int vertexSize );
2069
2078 void updateFields();
2079
2093 QVariant defaultValue( int index, const QgsFeature &feature = QgsFeature(),
2094 QgsExpressionContext *context = nullptr ) const;
2095
2106 void setDefaultValueDefinition( int index, const QgsDefaultValue &definition );
2107
2117 QgsDefaultValue defaultValueDefinition( int index ) const;
2118
2125 QgsFieldConstraints::Constraints fieldConstraints( int fieldIndex ) const;
2126
2131 QMap< QgsFieldConstraints::Constraint, QgsFieldConstraints::ConstraintStrength> fieldConstraintsAndStrength( int fieldIndex ) const;
2132
2141
2148 void removeFieldConstraint( int index, QgsFieldConstraints::Constraint constraint );
2149
2156 QString constraintExpression( int index ) const;
2157
2164 QString constraintDescription( int index ) const;
2165
2173 void setConstraintExpression( int index, const QString &expression, const QString &description = QString() );
2174
2180 void setFieldConfigurationFlags( int index, Qgis::FieldConfigurationFlags flags );
2181
2186 void setFieldConfigurationFlag( int index, Qgis::FieldConfigurationFlag flag, bool active );
2187
2193 Qgis::FieldConfigurationFlags fieldConfigurationFlags( int index ) const;
2194
2198 void setEditorWidgetSetup( int index, const QgsEditorWidgetSetup &setup );
2199
2205 QgsEditorWidgetSetup editorWidgetSetup( int index ) const;
2206
2218 QSet<QVariant> uniqueValues( int fieldIndex, int limit = -1 ) const FINAL;
2219
2233 QStringList uniqueStringsMatching( int index, const QString &substring, int limit = -1,
2234 QgsFeedback *feedback = nullptr ) const;
2235
2250 QVariant minimumValue( int index ) const FINAL;
2251
2266 QVariant maximumValue( int index ) const FINAL;
2267
2268
2288 void minimumAndMaximumValue( int index, QVariant &minimum SIP_OUT, QVariant &maximum SIP_OUT ) const;
2289
2303 QVariant aggregate( Qgis::Aggregate aggregate,
2304 const QString &fieldOrExpression,
2305 const QgsAggregateCalculator::AggregateParameters &parameters = QgsAggregateCalculator::AggregateParameters(),
2306 QgsExpressionContext *context = nullptr,
2307 bool *ok = nullptr,
2308 QgsFeatureIds *fids = nullptr,
2309 QgsFeedback *feedback = nullptr,
2310 QString *error SIP_PYARGREMOVE = nullptr ) const;
2311
2313 void setFeatureBlendMode( QPainter::CompositionMode blendMode );
2315 QPainter::CompositionMode featureBlendMode() const;
2316
2317 QString htmlMetadata() const FINAL;
2318
2322 void setSimplifyMethod( const QgsVectorSimplifyMethod &simplifyMethod ) { mSimplifyMethod = simplifyMethod; }
2323
2327 inline const QgsVectorSimplifyMethod &simplifyMethod() const { return mSimplifyMethod; }
2328
2333 bool simplifyDrawingCanbeApplied( const QgsRenderContext &renderContext, Qgis::VectorRenderingSimplificationFlag simplifyHint ) const;
2334
2341 QgsConditionalLayerStyles *conditionalStyles() const;
2342
2347 QgsAttributeTableConfig attributeTableConfig() const;
2348
2353 void setAttributeTableConfig( const QgsAttributeTableConfig &attributeTableConfig );
2354
2356
2357 QgsExpressionContextScope *createExpressionContextScope() const FINAL SIP_FACTORY;
2358
2365 QgsEditFormConfig editFormConfig() const;
2366
2372 void setEditFormConfig( const QgsEditFormConfig &editFormConfig );
2373
2380 void setReadExtentFromXml( bool readExtentFromXml );
2381
2388 bool readExtentFromXml() const;
2389
2394 bool isEditCommandActive() const { return mEditCommandActive; }
2395
2401 QgsGeometryOptions *geometryOptions() const;
2402
2420 bool allowCommit() const SIP_SKIP;
2421
2439 void setAllowCommit( bool allowCommit ) SIP_SKIP;
2440
2446 QgsStoredExpressionManager *storedExpressionManager() { return mStoredExpressionManager; }
2447
2448 public slots:
2449
2457 void select( QgsFeatureId featureId );
2458
2466 Q_INVOKABLE void select( const QgsFeatureIds &featureIds );
2467
2475 void deselect( QgsFeatureId featureId );
2476
2484 Q_INVOKABLE void deselect( const QgsFeatureIds &featureIds );
2485
2492 Q_INVOKABLE void removeSelection();
2493
2504 void reselect();
2505
2512 virtual void updateExtents( bool force = false );
2513
2528 Q_INVOKABLE bool startEditing();
2529
2535 virtual void setTransformContext( const QgsCoordinateTransformContext &transformContext ) override;
2536
2538
2539 bool accept( QgsStyleEntityVisitorInterface *visitor ) const override;
2540
2541 signals:
2542
2550 void selectionChanged( const QgsFeatureIds &selected, const QgsFeatureIds &deselected, bool clearAndSelect );
2551
2558
2561
2564
2570 void beforeCommitChanges( bool stopEditing );
2571
2574
2580
2586
2595 void attributeAdded( int idx );
2596
2603 void beforeAddingExpressionField( const QString &fieldName );
2604
2613 void attributeDeleted( int idx );
2614
2622
2629
2639
2649 void featuresDeleted( const QgsFeatureIds &fids );
2650
2656
2662
2671 void attributeValueChanged( QgsFeatureId fid, int idx, const QVariant &value );
2672
2680 void geometryChanged( QgsFeatureId fid, const QgsGeometry &geometry );
2681
2683 void committedAttributesDeleted( const QString &layerId, const QgsAttributeList &deletedAttributes );
2685 void committedAttributesAdded( const QString &layerId, const QList<QgsField> &addedAttributes );
2687 void committedFeaturesAdded( const QString &layerId, const QgsFeatureList &addedFeatures );
2689 void committedFeaturesRemoved( const QString &layerId, const QgsFeatureIds &deletedFeatureIds );
2691 void committedAttributeValuesChanges( const QString &layerId, const QgsChangedAttributesMap &changedAttributesValues );
2693 void committedGeometriesChanges( const QString &layerId, const QgsGeometryMap &changedGeometries );
2694
2696 void labelingFontNotFound( QgsVectorLayer *layer, const QString &fontfamily );
2697
2699 void featureBlendModeChanged( QPainter::CompositionMode blendMode );
2700
2706 void editCommandStarted( const QString &text );
2707
2714
2721
2731 void readCustomSymbology( const QDomElement &element, QString &errorMessage );
2732
2742 void writeCustomSymbology( QDomElement &element, QDomDocument &doc, QString &errorMessage ) const;
2743
2749
2753 void raiseError( const QString &msg );
2754
2760
2769
2776
2782
2783 protected:
2785 void setExtent( const QgsRectangle &rect ) FINAL;
2787 void setExtent3D( const QgsBox3D &rect ) FINAL;
2788
2789 private slots:
2790 void invalidateSymbolCountedFlag();
2791 void onFeatureCounterCompleted();
2792 void onFeatureCounterTerminated();
2793 void onJoinedFieldsChanged();
2794 void onFeatureDeleted( QgsFeatureId fid );
2795 void onRelationsLoaded();
2796 void onSymbolsCounted();
2797 void onDirtyTransaction( const QString &sql, const QString &name );
2798 void emitDataChanged();
2799 void onAfterCommitChangesDependency();
2800
2801 private:
2802 void updateDefaultValues( QgsFeatureId fid, QgsFeature feature = QgsFeature(), QgsExpressionContext *context = nullptr );
2803
2813 bool isReadOnly() const FINAL;
2814
2821 bool setDataProvider( QString const &provider, const QgsDataProvider::ProviderOptions &options, QgsDataProvider::ReadFlags flags = QgsDataProvider::ReadFlags() );
2822
2834 void setDataSourcePrivate( const QString &dataSource, const QString &baseName, const QString &provider, const QgsDataProvider::ProviderOptions &options, QgsDataProvider::ReadFlags flags ) override;
2835
2837 void readSldLabeling( const QDomNode &node );
2838
2840 bool readSldTextSymbolizer( const QDomNode &node, QgsPalLayerSettings &settings ) const;
2841
2843 QgsAbstractVectorLayerLabeling *readLabelingFromCustomProperties();
2844
2845 bool deleteFeatureCascade( QgsFeatureId fid, DeleteContext *context = nullptr );
2846
2847#ifdef SIP_RUN
2848 QgsVectorLayer( const QgsVectorLayer &rhs );
2849#endif
2851 void minimumOrMaximumValue( int index, QVariant *minimum, QVariant *maximum ) const;
2852
2853 void createEditBuffer();
2854 void clearEditBuffer();
2855
2856 QgsConditionalLayerStyles *mConditionalStyles = nullptr;
2857 QgsVectorDataProvider *mDataProvider = nullptr;
2858 QgsVectorLayerSelectionProperties *mSelectionProperties = nullptr;
2859 QgsVectorLayerTemporalProperties *mTemporalProperties = nullptr;
2860 QgsVectorLayerElevationProperties *mElevationProperties = nullptr;
2861
2863 QString mDisplayExpression;
2864
2866 QgsActionManager *mActions = nullptr;
2867
2869 bool mDataSourceReadOnly = false;
2870
2877 bool mReadOnly = false;
2878
2884 QgsFeatureIds mSelectedFeatureIds;
2885
2889 QgsFeatureIds mPreviousSelectedFeatureIds;
2890
2892 QgsFields mFields;
2893
2895 QgsStringMap mAttributeAliasMap;
2896
2898 QMap<QString, QgsDefaultValue> mDefaultExpressionMap;
2899
2901 QMap< QString, Qgis::FieldDomainSplitPolicy > mAttributeSplitPolicy;
2902
2904 QMap< QString, Qgis::FieldDuplicatePolicy > mAttributeDuplicatePolicy;
2905
2907 QSet<int> mDefaultValueOnUpdateFields;
2908
2910 QMap< QString, QgsFieldConstraints::Constraints > mFieldConstraints;
2911
2913 QMap< QPair< QString, QgsFieldConstraints::Constraint >, QgsFieldConstraints::ConstraintStrength > mFieldConstraintStrength;
2914
2916 QMap< QString, QPair< QString, QString > > mFieldConstraintExpressions;
2917
2918 QMap< QString, Qgis::FieldConfigurationFlags > mFieldConfigurationFlags;
2919 QMap< QString, QgsEditorWidgetSetup > mFieldWidgetSetups;
2920
2922 QgsEditFormConfig mEditFormConfig;
2923
2926
2928 QgsFeatureRenderer *mRenderer = nullptr;
2929
2931 QgsVectorSimplifyMethod mSimplifyMethod;
2932
2934 QgsAbstractVectorLayerLabeling *mLabeling = nullptr;
2935
2937 bool mLabelsEnabled = false;
2938
2940 bool mLabelFontNotFoundNotified = false;
2941
2943 QPainter::CompositionMode mFeatureBlendMode = QPainter::CompositionMode_SourceOver;
2944
2946 bool mVertexMarkerOnlyForSelection = false;
2947
2948 QStringList mCommitErrors;
2949
2951 QgsVectorLayerEditBuffer *mEditBuffer = nullptr;
2955
2956 //stores information about joined layers
2957 QgsVectorLayerJoinBuffer *mJoinBuffer = nullptr;
2958
2960 QgsExpressionFieldBuffer *mExpressionFieldBuffer = nullptr;
2961
2962 //diagram rendering object. 0 if diagram drawing is disabled
2963 QgsDiagramRenderer *mDiagramRenderer = nullptr;
2964
2965 //stores infos about diagram placement (placement type, priority, position distance)
2966 QgsDiagramLayerSettings *mDiagramLayerSettings = nullptr;
2967
2968 mutable bool mValidExtent2D = false;
2969 mutable bool mLazyExtent2D = true;
2970 mutable bool mValidExtent3D = false;
2971 mutable bool mLazyExtent3D = true;
2972
2974 std::unique_ptr<QgsAuxiliaryLayer> mAuxiliaryLayer;
2975
2977 QString mAuxiliaryLayerKey;
2978
2979 // Features in renderer classes counted
2980 bool mSymbolFeatureCounted = false;
2981
2982 // Feature counts for each renderer legend key
2983 QHash<QString, long long> mSymbolFeatureCountMap;
2984 QHash<QString, QgsFeatureIds> mSymbolFeatureIdMap;
2985
2987 bool mEditCommandActive = false;
2988
2990 bool mCommitChangesActive = false;
2991
2992 bool mReadExtentFromXml;
2993 QgsRectangle mXmlExtent2D;
2994 QgsBox3D mXmlExtent3D;
2995
2996 QgsFeatureIds mDeletedFids;
2997
2998 QgsAttributeTableConfig mAttributeTableConfig;
2999
3000 mutable QMutex mFeatureSourceConstructorMutex;
3001
3002 QgsVectorLayerFeatureCounter *mFeatureCounter = nullptr;
3003
3004 std::unique_ptr<QgsGeometryOptions> mGeometryOptions;
3005
3006 bool mAllowCommit = true;
3007
3009 QgsStoredExpressionManager *mStoredExpressionManager = nullptr;
3010
3012
3014 bool mDataChangedFired = false;
3015
3016 QList<QgsWeakRelation> mWeakRelations;
3017
3018 bool mSetLegendFromStyle = false;
3019
3020 QList< QgsFeatureRendererGenerator * > mRendererGenerators;
3021
3023 QTimer *mRefreshRendererTimer = nullptr;
3024
3028 bool mLoadAllStoredStyle = false;
3029
3030};
3031
3032
3033
3034// clazy:excludeall=qstring-allocations
3035
3036#endif
The Qgis class provides global constants for use throughout the application.
Definition qgis.h:54
GeometryOperationResult
Success or failure of a geometry operation.
Definition qgis.h:1709
SpatialIndexPresence
Enumeration of spatial index presence states.
Definition qgis.h:368
VectorRenderingSimplificationFlag
Simplification flags for vector feature rendering.
Definition qgis.h:2577
FieldDomainSplitPolicy
Split policy for field domains.
Definition qgis.h:3332
GeometryType
The geometry types are used to group Qgis::WkbType in a coarse way.
Definition qgis.h:274
FieldDuplicatePolicy
Duplicate policy for fields.
Definition qgis.h:3364
VertexMarkerType
Editing vertex markers, used for showing vertices during a edit operation.
Definition qgis.h:1500
WkbType
The WKB type describes the number of dimensions a geometry has.
Definition qgis.h:201
@ Unknown
Unknown.
FieldConfigurationFlag
Configuration flags for fields These flags are meant to be user-configurable and are not describing a...
Definition qgis.h:1388
QFlags< FieldConfigurationFlag > FieldConfigurationFlags
Configuration flags for fields These flags are meant to be user-configurable and are not describing a...
Definition qgis.h:1403
SelectBehavior
Specifies how a selection should be applied.
Definition qgis.h:1438
@ SetSelection
Set selection, removing any existing selection.
Abstract base class for simplify geometries using a specific algorithm.
Abstract base class for objects which generate elevation profiles.
Interface for classes which can generate elevation profiles.
Abstract base class - its implementations define different approaches to the labeling of a vector lay...
Storage and management of actions associated with a layer.
Utility class for calculating aggregates for a field (or expression) over the features from a vector ...
This is a container for configuration of the attribute table.
Class allowing to manage the auxiliary storage for a vector layer.
Class providing some utility methods to manage auxiliary storage.
A 3-dimensional box composed of x, y, z coordinates.
Definition qgsbox3d.h:43
The QgsConditionalLayerStyles class holds conditional style information for a layer.
This class represents a coordinate reference system (CRS).
Contains information about the context in which a coordinate transform is executed.
Abstract base class for curved geometry type.
Definition qgscurve.h:35
Abstract base class for spatial data provider implementations.
The QgsDefaultValue class provides a container for managing client side default values for fields.
Stores the settings for rendering of all diagrams for a layer.
Evaluates and returns the diagram settings relating to a diagram for a specific feature.
Contains configuration settings for an editor form.
Holder for the widget type and its configuration for a field.
Manages an editor widget Widget and wrapper share the same parent.
Abstract interface for generating an expression context.
virtual QgsExpressionContext createExpressionContext() const =0
This method needs to be reimplemented in all classes which implement this interface and return an exp...
Abstract interface for generating an expression context scope.
Single scope for storing variables and functions for use within a QgsExpressionContext.
Expression contexts are used to encapsulate the parameters around which a QgsExpression should be eva...
Buffers information about expression fields for a vector layer.
Wrapper for iterator of features from vector data provider or vector layer.
bool nextFeature(QgsFeature &f)
Fetch next feature and stores in f, returns true on success.
An interface for objects which generate feature renderers for vector layers.
This class wraps a request for features to a vector layer (or directly its vector data provider).
An interface for objects which accept features via addFeature(s) methods.
virtual bool addFeature(QgsFeature &feature, QgsFeatureSink::Flags flags=QgsFeatureSink::Flags())
Adds a single feature to the sink.
QFlags< Flag > Flags
An interface for objects which provide features via a getFeatures method.
virtual QSet< QVariant > uniqueValues(int fieldIndex, int limit=-1) const
Returns the set of unique values contained within the specified fieldIndex from this source.
virtual Qgis::WkbType wkbType() const =0
Returns the geometry type for features returned by this source.
virtual Qgis::SpatialIndexPresence hasSpatialIndex() const
Returns an enum value representing the presence of a valid spatial index on the source,...
virtual QgsFeatureIterator getFeatures(const QgsFeatureRequest &request=QgsFeatureRequest()) const =0
Returns an iterator for the features in the source.
virtual long long featureCount() const =0
Returns the number of features contained in the source, or -1 if the feature count is unknown.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
Definition qgsfeature.h:58
Base class for feedback objects to be used for cancellation of something running in a worker thread.
Definition qgsfeedback.h:44
ConstraintStrength
Strength of constraints.
@ ConstraintStrengthHard
Constraint must be honored before feature can be accepted.
Constraint
Constraints which may be present on a field.
QFlags< Constraint > Constraints
Encapsulate a field in an attribute table or data source.
Definition qgsfield.h:53
Container of fields for a vector layer.
Definition qgsfields.h:46
QgsAttributeList allAttributesList() const
Utility function to get list of attribute indexes.
The QgsGeometryOptions class contains options to automatically adjust geometries to constraints on a ...
A geometry is the spatial representation of a feature.
Base class for storage of map layer elevation properties.
Base class for utility classes that encapsulate information necessary for rendering of map layers.
Base class for storage of map layer selection properties.
Base class for storage of map layer temporal properties.
Base class for all map layer types.
Definition qgsmaplayer.h:75
virtual bool accept(QgsStyleEntityVisitorInterface *visitor) const
Accepts the specified symbology visitor, causing it to visit all symbols associated with the layer.
QFlags< ReadFlag > ReadFlags
virtual bool setDependencies(const QSet< QgsMapLayerDependency > &layers)
Sets the list of dependencies.
virtual void setExtent3D(const QgsBox3D &box)
Sets the extent.
virtual QSet< QgsMapLayerDependency > dependencies() const
Gets the list of dependencies.
friend class QgsVectorLayer
virtual bool isEditable() const
Returns true if the layer can be edited.
virtual QgsMapLayer * clone() const =0
Returns a new instance equivalent to this one except for the id which is still unique.
virtual void setExtent(const QgsRectangle &rect)
Sets the extent.
virtual void setTransformContext(const QgsCoordinateTransformContext &transformContext)=0
Sets the coordinate transform context to transformContext.
Perform transforms between map coordinates and device coordinates.
Contains settings for how a map layer will be labeled.
A class to represent a 2D point.
Definition qgspointxy.h:60
Point geometry type, with support for z-dimension and m-values.
Definition qgspoint.h:49
Encapsulates properties and constraints relating to fetching elevation profiles from different source...
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
Definition qgsproject.h:107
The class is used as a container of context for various read/write operations on other objects.
A rectangle specified with double values.
This class manages a set of relations between layers.
Contains information about the context of a rendering operation.
A boolean settings entry.
A double settings entry.
A template class for enum and flag settings entry.
Manages stored expressions regarding creation, modification and storing in the project.
An interface for classes which can visit style entity (e.g.
Abstract base class for all rendered symbols.
Definition qgssymbol.h:94
This is the base class for vector data providers.
The edit buffer group manages a group of edit buffers.
Vector layer specific subclass of QgsMapLayerElevationProperties.
Counts the features in a QgsVectorLayer in task.
Partial snapshot of vector layer's state (only the members necessary for access to features)
Manages joined fields for a vector layer.
Defines left outer join from our vector layer to some other vector layer.
Implementation of layer selection properties for vector layers.
Implementation of map layer temporal properties for vector layers.
Contains settings which reflect the context in which vector layer tool operations should consider.
Represents a vector layer which manages a vector based data sets.
void committedFeaturesAdded(const QString &layerId, const QgsFeatureList &addedFeatures)
Emitted when features are added to the provider if not in transaction mode.
void labelingFontNotFound(QgsVectorLayer *layer, const QString &fontfamily)
Emitted when the font family defined for labeling layer is not found on system.
void featureBlendModeChanged(QPainter::CompositionMode blendMode)
Signal emitted when setFeatureBlendMode() is called.
void beforeRemovingExpressionField(int idx)
Will be emitted, when an expression field is going to be deleted from this vector layer.
void committedGeometriesChanges(const QString &layerId, const QgsGeometryMap &changedGeometries)
Emitted when geometry changes are saved to the provider if not in transaction mode.
void beforeCommitChanges(bool stopEditing)
Emitted before changes are committed to the data provider.
void attributeAdded(int idx)
Will be emitted, when a new attribute has been added to this vector layer.
QgsAbstractVectorLayerLabeling * labeling()
Access to labeling configuration.
void allowCommitChanged()
Emitted whenever the allowCommitChanged() property of this layer changes.
void editCommandStarted(const QString &text)
Signal emitted when a new edit command has been started.
const QgsDiagramLayerSettings * diagramLayerSettings() const
const QgsVectorLayerJoinBuffer * joinBuffer() const
Returns a const pointer on join buffer object.
void editCommandDestroyed()
Signal emitted, when an edit command is destroyed.
QgsVectorLayer(const QgsVectorLayer &rhs)=delete
QgsVectorLayer cannot be copied.
void featuresDeleted(const QgsFeatureIds &fids)
Emitted when features have been deleted.
void subsetStringChanged()
Emitted when the layer's subset string has changed.
void committedFeaturesRemoved(const QString &layerId, const QgsFeatureIds &deletedFeatureIds)
Emitted when features are deleted from the provider if not in transaction mode.
void symbolFeatureCountMapChanged()
Emitted when the feature count for symbols on this layer has been recalculated.
void writeCustomSymbology(QDomElement &element, QDomDocument &doc, QString &errorMessage) const
Signal emitted whenever the symbology (QML-file) for this layer is being written.
void attributeDeleted(int idx)
Will be emitted, when an attribute has been deleted from this vector layer.
QgsVectorLayer & operator=(QgsVectorLayer const &rhs)=delete
QgsVectorLayer cannot be copied.
QgsFeatureRenderer * renderer()
Returns the feature renderer used for rendering the features in the layer in 2D map views.
void beforeEditingStarted()
Emitted before editing on this layer is started.
void committedAttributeValuesChanges(const QString &layerId, const QgsChangedAttributesMap &changedAttributesValues)
Emitted when attribute value changes are saved to the provider if not in transaction mode.
void committedAttributesAdded(const QString &layerId, const QList< QgsField > &addedAttributes)
Emitted when attributes are added to the provider if not in transaction mode.
void committedAttributesDeleted(const QString &layerId, const QgsAttributeList &deletedAttributes)
Emitted when attributes are deleted from the provider if not in transaction mode.
void displayExpressionChanged()
Emitted when the display expression changes.
const QgsActionManager * actions() const
Returns all layer actions defined on this layer.
void editFormConfigChanged()
Will be emitted whenever the edit form configuration of this layer changes.
void afterCommitChanges()
Emitted after changes are committed to the data provider.
void raiseError(const QString &msg)
Signals an error related to this vector layer.
void editCommandEnded()
Signal emitted, when an edit command successfully ended.
void supportsEditingChanged()
Emitted when the read only state or the data provider of this layer is changed.
void readOnlyChanged()
Emitted when the read only state of this layer is changed.
void attributeValueChanged(QgsFeatureId fid, int idx, const QVariant &value)
Emitted whenever an attribute value change is done in the edit buffer.
QgsFeatureIterator getFeatures(const QgsFeatureIds &fids)
Queries the layer for the features with the given ids.
void afterRollBack()
Emitted after changes are rolled back.
const QgsVectorSimplifyMethod & simplifyMethod() const
Returns the simplification settings for fast rendering of features.
void selectionChanged(const QgsFeatureIds &selected, const QgsFeatureIds &deselected, bool clearAndSelect)
Emitted when selection was changed.
void beforeAddingExpressionField(const QString &fieldName)
Will be emitted, when an expression field is going to be added to this vector layer.
void updatedFields()
Emitted whenever the fields available from this layer have been changed.
void featureAdded(QgsFeatureId fid)
Emitted when a new feature has been added to the layer.
void featureDeleted(QgsFeatureId fid)
Emitted when a feature has been deleted.
void readCustomSymbology(const QDomElement &element, QString &errorMessage)
Signal emitted whenever the symbology (QML-file) for this layer is being read.
const QgsVectorLayerEditBuffer * editBuffer() const
Buffer with uncommitted editing operations.
void beforeRollBack()
Emitted before changes are rolled back.
void geometryChanged(QgsFeatureId fid, const QgsGeometry &geometry)
Emitted whenever a geometry change is done in the edit buffer.
QgsFeatureIterator getFeatures(const QgsRectangle &rectangle)
Queries the layer for the features which intersect the specified rectangle.
const QgsFeatureRenderer * renderer() const
Returns the feature renderer used for rendering the features in the layer in 2D map views.
void beforeModifiedCheck() const
Emitted when the layer is checked for modifications. Use for last-minute additions.
Q_INVOKABLE QgsFeature getFeature(QgsFeatureId fid) const
Queries the layer for the feature with the given id.
const QgsDiagramRenderer * diagramRenderer() const
This class contains information how to simplify geometries fetched from a vector layer.
The QgsWeakRelation class represent a QgsRelation with possibly unresolved layers or unmatched fields...
#define str(x)
Definition qgis.cpp:38
QMap< QString, QString > QgsStringMap
Definition qgis.h:5983
#define SIP_DEPRECATED
Definition qgis_sip.h:106
#define SIP_SKIP
Definition qgis_sip.h:126
#define FINAL
Definition qgis_sip.h:242
#define SIP_PYNAME(name)
Definition qgis_sip.h:81
#define SIP_PYARGREMOVE
Definition qgis_sip.h:151
#define SIP_TRANSFER
Definition qgis_sip.h:36
#define SIP_OUT
Definition qgis_sip.h:58
#define SIP_FACTORY
Definition qgis_sip.h:76
QVector< QgsPoint > QgsPointSequence
QMap< int, QVariant > QgsAttributeMap
QMap< QgsFeatureId, QgsGeometry > QgsGeometryMap
QMap< QgsFeatureId, QgsAttributeMap > QgsChangedAttributesMap
QList< QgsFeature > QgsFeatureList
QSet< QgsFeatureId > QgsFeatureIds
qint64 QgsFeatureId
64 bit feature ids negative numbers are used for uncommitted/newly added features
QList< int > QgsAttributeList
Definition qgsfield.h:27
QList< int > QgsAttributeList
QSet< int > QgsAttributeIds
Context for cascade delete features.
DeleteContext(bool cascade=false, QgsProject *project=nullptr)
Constructor for DeleteContext.
Setting options for loading vector layers.
LayerOptions(bool loadDefaultStyle=true, bool readExtentFromXml=false)
Constructor for LayerOptions.
LayerOptions(const QgsCoordinateTransformContext &transformContext, bool loadDefaultStyle=true, bool readExtentFromXml=false)
Constructor for LayerOptions.
QgsCoordinateReferenceSystem fallbackCrs
Fallback layer coordinate reference system.