QGIS API Documentation 3.40.0-Bratislava (b56115d8743)
|
A model for representing the sublayers present in a URI for the QgsProviderSublayersDialog. More...
#include <qgsprovidersublayersdialog.h>
Public Member Functions | |
QgsProviderSublayerDialogModel (QObject *parent=nullptr) | |
Constructor. | |
QVariant | data (const QModelIndex &index, int role) const override |
Qt::ItemFlags | flags (const QModelIndex &index) const override |
void | setGeometryTypesResolved (bool resolved) |
Sets whether geometry types are resolved. | |
Public Member Functions inherited from QgsProviderSublayerModel | |
QgsProviderSublayerModel (QObject *parent=nullptr) | |
Constructor for QgsProviderSublayerModel, with the specified parent object. | |
void | addNonLayerItem (const QgsProviderSublayerModel::NonLayerItem &item) |
Adds a non-layer item (e.g. | |
int | columnCount (const QModelIndex &parent=QModelIndex()) const override |
QVariant | data (const QModelIndex &index, int role) const override |
Qt::ItemFlags | flags (const QModelIndex &index) const override |
QVariant | headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override |
QModelIndex | index (int row, int column, const QModelIndex &parent=QModelIndex()) const override |
QgsProviderSublayerModel::NonLayerItem | indexToNonLayerItem (const QModelIndex &index) const |
Returns the non layer item corresponding to the given index. | |
QgsProviderSublayerDetails | indexToSublayer (const QModelIndex &index) const |
Returns the sublayer corresponding to the given index. | |
QModelIndex | parent (const QModelIndex &index) const override |
int | rowCount (const QModelIndex &parent) const override |
void | setSublayerDetails (const QList< QgsProviderSublayerDetails > &details) |
Sets the sublayer details to show in the model. | |
QList< QgsProviderSublayerDetails > | sublayerDetails () const |
Returns the sublayer details shown in the model. | |
Additional Inherited Members | |
Public Types inherited from QgsProviderSublayerModel | |
enum class | Column : int { Name = 0 , Description = 1 } |
Model columns. More... | |
enum class | Role : int { ProviderKey = Qt::UserRole + 1 , LayerType , Uri , Name , Description , Path , FeatureCount , WkbType , GeometryColumnName , LayerNumber , IsNonLayerItem , NonLayerItemType , Flags } |
Custom model roles. More... | |
Protected Attributes inherited from QgsProviderSublayerModel | |
std::unique_ptr< QgsProviderSublayerModelGroup > | mRootNode |
QList< QgsProviderSublayerDetails > | mSublayers |
Sublayer list. | |
A model for representing the sublayers present in a URI for the QgsProviderSublayersDialog.
Definition at line 39 of file qgsprovidersublayersdialog.h.
QgsProviderSublayerDialogModel::QgsProviderSublayerDialogModel | ( | QObject * | parent = nullptr | ) |
Constructor.
Definition at line 32 of file qgsprovidersublayersdialog.cpp.
|
override |
Definition at line 38 of file qgsprovidersublayersdialog.cpp.
|
override |
Definition at line 88 of file qgsprovidersublayersdialog.cpp.
void QgsProviderSublayerDialogModel::setGeometryTypesResolved | ( | bool | resolved | ) |
Sets whether geometry types are resolved.
Definition at line 109 of file qgsprovidersublayersdialog.cpp.