QGIS/python/core/auto_generated/qgspluginlayerregistry.sip.in

112 lines
3.0 KiB
Plaintext
Raw Normal View History

/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgspluginlayerregistry.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/
class QgsPluginLayerType
{
%Docstring
class for creating plugin specific layers
%End
%TypeHeaderCode
#include "qgspluginlayerregistry.h"
%End
public:
QgsPluginLayerType( const QString &name );
virtual ~QgsPluginLayerType();
QString name();
virtual QgsPluginLayer *createLayer() /Factory/;
%Docstring
2019-02-26 09:11:18 +10:00
Returns new layer of this type. Return None on error
%End
virtual QgsPluginLayer *createLayer( const QString &uri ) /Factory/;
%Docstring
2019-02-26 09:11:18 +10:00
Returns new layer of this type, using layer URI (specific to this plugin layer type). Return None on error.
2017-12-15 10:36:55 -04:00
.. versionadded:: 2.10
%End
2015-03-18 14:17:32 +07:00
virtual bool showLayerProperties( QgsPluginLayer *layer );
%Docstring
2019-02-26 19:54:09 +10:00
Show plugin layer properties dialog. Return ``False`` if the dialog cannot be shown.
%End
protected:
};
class QgsPluginLayerRegistry
{
%Docstring
2017-12-15 10:36:55 -04:00
A registry of plugin layers types.
2017-12-15 10:36:55 -04:00
QgsPluginLayerRegistry is not usually directly created, but rather accessed through
2017-12-19 11:43:52 -04:00
:py:func:`QgsApplication.pluginLayerRegistry()`
%End
%TypeHeaderCode
#include "qgspluginlayerregistry.h"
%End
public:
QgsPluginLayerRegistry();
2017-09-11 21:43:15 +10:00
%Docstring
2017-12-15 10:36:55 -04:00
Constructor for QgsPluginLayerRegistry.
2017-09-11 21:43:15 +10:00
%End
~QgsPluginLayerRegistry();
QStringList pluginLayerTypes();
%Docstring
2017-12-15 10:36:55 -04:00
List all known layer types
%End
bool addPluginLayerType( QgsPluginLayerType *pluginLayerType /Transfer/ );
%Docstring
2019-02-26 19:54:09 +10:00
Add plugin layer type (take ownership) and return ``True`` on success
%End
bool removePluginLayerType( const QString &typeName );
%Docstring
2019-02-26 19:54:09 +10:00
Remove plugin layer type and return ``True`` on success
%End
QgsPluginLayerType *pluginLayerType( const QString &typeName );
%Docstring
2019-02-26 09:11:18 +10:00
Returns plugin layer type metadata or None if doesn't exist
%End
QgsPluginLayer *createLayer( const QString &typeName, const QString &uri = QString() ) /Factory/;
%Docstring
2017-12-15 10:36:55 -04:00
Returns new layer if corresponding plugin has been found else returns a None.
.. note::
parameter uri has been added in QGIS 2.10
%End
private:
QgsPluginLayerRegistry( const QgsPluginLayerRegistry &rh );
};
/************************************************************************
* This file has been generated automatically from *
* *
* src/core/qgspluginlayerregistry.h *
* *
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
************************************************************************/