2017-09-01 17:47:55 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/qgssourceselectproviderregistry.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-06-04 15:52:50 +02:00
|
|
|
|
2019-06-20 10:49:36 +02:00
|
|
|
|
2017-09-01 17:47:55 +02:00
|
|
|
class QgsSourceSelectProviderRegistry
|
|
|
|
{
|
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
This class keeps a list of source select providers that may add items to the QgsDataSourceManagerDialog
|
|
|
|
When created, it automatically adds providers from data provider plugins (e.g. PostGIS, WMS, ...)
|
2017-09-01 17:47:55 +02:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
QgsSourceSelectProviderRegistry is not usually directly created, but rather accessed through
|
2017-12-19 11:43:52 -04:00
|
|
|
:py:func:`QgsGui.sourceSelectProviderRegistry()`
|
2017-09-04 08:00:14 +02:00
|
|
|
|
2017-09-01 17:47:55 +02:00
|
|
|
.. versionadded:: 3.0
|
|
|
|
%End
|
|
|
|
|
|
|
|
%TypeHeaderCode
|
|
|
|
#include "qgssourceselectproviderregistry.h"
|
|
|
|
%End
|
2017-09-01 18:20:06 +02:00
|
|
|
public:
|
2017-09-11 21:43:15 +10:00
|
|
|
|
2019-06-20 16:00:06 +02:00
|
|
|
QgsSourceSelectProviderRegistry();
|
2017-09-01 18:20:06 +02:00
|
|
|
~QgsSourceSelectProviderRegistry();
|
2017-09-01 17:47:55 +02:00
|
|
|
|
|
|
|
|
2017-09-04 09:10:56 +02:00
|
|
|
QList< QgsSourceSelectProvider *> providers();
|
2017-09-01 17:47:55 +02:00
|
|
|
%Docstring
|
2018-05-26 18:44:30 +10:00
|
|
|
Gets list of available providers
|
2017-09-01 17:47:55 +02:00
|
|
|
%End
|
|
|
|
|
2017-09-01 18:20:06 +02:00
|
|
|
void addProvider( QgsSourceSelectProvider *provider /Transfer/ );
|
2017-09-01 17:47:55 +02:00
|
|
|
%Docstring
|
2017-09-04 15:15:20 +02:00
|
|
|
Add a ``provider`` implementation. Takes ownership of the object.
|
2017-09-01 17:47:55 +02:00
|
|
|
%End
|
|
|
|
|
2017-09-04 15:15:20 +02:00
|
|
|
bool removeProvider( QgsSourceSelectProvider *provider /Transfer/ );
|
2017-09-01 17:47:55 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
Remove ``provider`` implementation from the list (``provider`` object is deleted)
|
|
|
|
|
2019-02-26 19:54:09 +10:00
|
|
|
:return: ``True`` if the provider was actually removed and deleted
|
2019-06-20 16:00:06 +02:00
|
|
|
%End
|
|
|
|
|
|
|
|
void initializeFromProviderGuiRegistry( QgsProviderGuiRegistry *providerGuiRegistry );
|
|
|
|
%Docstring
|
|
|
|
Initializes the registry. The registry needs to be passed explicitly
|
|
|
|
(instead of using singleton) because this gets called from QgsGui constructor.
|
|
|
|
|
|
|
|
.. versionadded:: 3.10
|
2017-09-01 17:47:55 +02:00
|
|
|
%End
|
|
|
|
|
2017-09-04 09:10:56 +02:00
|
|
|
QgsSourceSelectProvider *providerByName( const QString &name );
|
2017-09-01 17:47:55 +02:00
|
|
|
%Docstring
|
2019-02-26 21:19:42 +10:00
|
|
|
Returns a provider by ``name`` or ``None`` if not found
|
2017-09-01 17:47:55 +02:00
|
|
|
%End
|
|
|
|
|
2017-09-04 09:10:56 +02:00
|
|
|
QList<QgsSourceSelectProvider *> providersByKey( const QString &providerKey );
|
2017-09-01 17:47:55 +02:00
|
|
|
%Docstring
|
2018-05-25 13:54:27 +10:00
|
|
|
Returns a (possibly empty) list of providers by data ``providerkey``
|
2017-09-01 17:47:55 +02:00
|
|
|
%End
|
|
|
|
|
2019-06-04 15:52:50 +02:00
|
|
|
QgsAbstractDataSourceWidget *createSelectionWidget(
|
|
|
|
const QString &name,
|
|
|
|
QWidget *parent,
|
|
|
|
Qt::WindowFlags fl,
|
2019-06-20 10:49:36 +02:00
|
|
|
QgsProviderRegistry::WidgetMode widgetMode
|
2019-06-04 15:52:50 +02:00
|
|
|
);
|
|
|
|
%Docstring
|
|
|
|
Gets select widget from provider with ``name``
|
|
|
|
|
|
|
|
The function is replacement of QgsProviderRegistry.createSelectionWidget() from QGIS 3.8
|
2017-09-01 17:47:55 +02:00
|
|
|
|
2019-06-04 15:52:50 +02:00
|
|
|
.. versionadded:: 3.10
|
|
|
|
%End
|
2019-09-02 16:49:36 +02:00
|
|
|
|
2017-09-01 18:20:06 +02:00
|
|
|
private:
|
|
|
|
QgsSourceSelectProviderRegistry( const QgsSourceSelectProviderRegistry &rh );
|
2017-09-01 17:47:55 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/gui/qgssourceselectproviderregistry.h *
|
|
|
|
* *
|
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
|
|
************************************************************************/
|