QGIS API Documentation 3.41.0-Master (af5edcb665c)
Loading...
Searching...
No Matches
Public Member Functions | List of all members
QgsSubsetStringEditorProvider Class Referenceabstract

This is the interface for those who want to provide a dialog to edit a subset string. More...

#include <qgssubsetstringeditorprovider.h>

Public Member Functions

virtual ~QgsSubsetStringEditorProvider ()
 
virtual bool canHandleLayer (QgsVectorLayer *layer) const =0
 Returns true if the provider can handle the layer.
 
virtual bool canHandleLayerStorageType (QgsVectorLayer *layer) const
 Returns true if the provider can handle specifically the layer->provider()->storageType() This method will only be called if canHandleLayer() returned true.
 
virtual QgsSubsetStringEditorInterfacecreateDialog (QgsVectorLayer *layer, QWidget *parent=nullptr, Qt::WindowFlags fl=QgsGuiUtils::ModalDialogFlags)=0
 Creates a new dialog to edit the subset string of the provided layer.
 
virtual QString name () const
 Subset string editor provider name, this is useful to retrieve a particular subset string editor in case the provider has more than one, it should be unique among all providers.
 
virtual QString providerKey () const =0
 Provider key.
 

Detailed Description

This is the interface for those who want to provide a dialog to edit a subset string.

Since
QGIS 3.18

Definition at line 37 of file qgssubsetstringeditorprovider.h.

Constructor & Destructor Documentation

◆ ~QgsSubsetStringEditorProvider()

QgsSubsetStringEditorProvider::~QgsSubsetStringEditorProvider ( )
virtualdefault

Member Function Documentation

◆ canHandleLayer()

virtual bool QgsSubsetStringEditorProvider::canHandleLayer ( QgsVectorLayer layer) const
pure virtual

Returns true if the provider can handle the layer.

◆ canHandleLayerStorageType()

virtual bool QgsSubsetStringEditorProvider::canHandleLayerStorageType ( QgsVectorLayer layer) const
inlinevirtual

Returns true if the provider can handle specifically the layer->provider()->storageType() This method will only be called if canHandleLayer() returned true.

Typically a generic SQL provider for the OGR provider will return false, whereas a dedicated plugin with a specific behavior for a OGR driver will return true.

Definition at line 65 of file qgssubsetstringeditorprovider.h.

◆ createDialog()

virtual QgsSubsetStringEditorInterface * QgsSubsetStringEditorProvider::createDialog ( QgsVectorLayer layer,
QWidget *  parent = nullptr,
Qt::WindowFlags  fl = QgsGuiUtils::ModalDialogFlags 
)
pure virtual

Creates a new dialog to edit the subset string of the provided layer.

It may return nullptr if it cannot handle the layer. The returned object must be destroyed by the caller. On successful accept(), the QgsSubsetStringEditorInterface implementation is responsible for setting the updated string on layer.

◆ name()

virtual QString QgsSubsetStringEditorProvider::name ( ) const
inlinevirtual

Subset string editor provider name, this is useful to retrieve a particular subset string editor in case the provider has more than one, it should be unique among all providers.

The default implementation returns the providerKey()

Definition at line 52 of file qgssubsetstringeditorprovider.h.

◆ providerKey()

virtual QString QgsSubsetStringEditorProvider::providerKey ( ) const
pure virtual

Provider key.


The documentation for this class was generated from the following files: