QgsPluginLayerRegistry class

A registry of plugin layers types.

QgsPluginLayerRegistry is not usually directly created, but rather accessed through QgsApplication::pluginLayerRegistry().

Constructors, destructors, conversion operators

QgsPluginLayerRegistry() defaulted
Constructor for QgsPluginLayerRegistry.
QgsPluginLayerRegistry(const QgsPluginLayerRegistry& rh) deleted
QgsPluginLayerRegistry cannot be copied.

Public functions

auto addPluginLayerType(QgsPluginLayerType* pluginLayerType) -> bool
Add plugin layer type (take ownership) and return true on success.
auto createLayer(const QString& typeName, const QString& uri = QString()) -> QgsPluginLayer*
Returns new layer if corresponding plugin has been found else returns a nullptr.
auto operator=(const QgsPluginLayerRegistry& rh) -> QgsPluginLayerRegistry& deleted
QgsPluginLayerRegistry cannot be copied.
auto pluginLayerType(const QString& typeName) -> QgsPluginLayerType*
Returns plugin layer type metadata or NULL if doesn't exist.
auto pluginLayerTypes() -> QStringList
List all known layer types.
auto removePluginLayerType(const QString& typeName) -> bool
Remove plugin layer type and return true on success.

Function documentation

QgsPluginLayer* QgsPluginLayerRegistry::createLayer(const QString& typeName, const QString& uri = QString())

Returns new layer if corresponding plugin has been found else returns a nullptr.

QStringList QgsPluginLayerRegistry::pluginLayerTypes()

List all known layer types.