QGIS API Documentation 3.41.0-Master (fda2aa46e9a)
|
Contains utility functions for creating map layers. More...
#include <qgsmaplayerfactory.h>
Classes | |
struct | LayerOptions |
Setting options for loading layers. More... | |
Static Public Member Functions | |
static QgsMapLayer * | createLayer (const QString &uri, const QString &name, Qgis::LayerType type, const LayerOptions &options, const QString &provider=QString()) |
Creates a map layer, given a uri, name, layer type and provider name. | |
static Qgis::LayerType | typeFromString (const QString &string, bool &ok) |
Returns the map layer type corresponding a string value. | |
static QString | typeToString (Qgis::LayerType type) |
Converts a map layer type to a string value. | |
Contains utility functions for creating map layers.
Definition at line 36 of file qgsmaplayerfactory.h.
|
static |
Creates a map layer, given a uri, name, layer type and provider name.
Caller takes ownership of the returned layer.
Definition at line 80 of file qgsmaplayerfactory.cpp.
|
static |
Returns the map layer type corresponding a string value.
string | string to convert to map layer type |
ok | will be set to true if string was successfully converted to a map layer type |
Definition at line 28 of file qgsmaplayerfactory.cpp.
|
static |
Converts a map layer type to a string value.
Definition at line 54 of file qgsmaplayerfactory.cpp.