15 #ifndef QGSLAYERDEFINITION_H 16 #define QGSLAYERDEFINITION_H 19 #include "qgis_core.h" 50 static bool exportLayerDefinition( QString path,
const QList<QgsLayerTreeNode *> &selectedTreeNodes, QString &errorMessage SIP_OUT );
52 static bool exportLayerDefinition( QDomDocument doc,
const QList<QgsLayerTreeNode *> &selectedTreeNodes, QString &errorMessage SIP_OUT,
const QgsReadWriteContext &context );
63 static QDomDocument exportLayerDefinitionLayers(
const QList<QgsMapLayer *> &layers,
const QgsReadWriteContext &context );
77 static QList<QgsMapLayer *> loadLayerDefinitionLayers(
const QString &qlrfile )
SIP_FACTORY;
112 QVector<QDomNode> mSortedLayerNodes;
113 QStringList mSortedLayerIds;
115 bool mHasMissingDependency;
116 void init(
const QDomDocument &doc );
120 #endif // QGSLAYERDEFINITION_H Layer tree group node serves as a container for layers and further groups.
The class is used as a container of context for various read/write operations on other objects...
Base class for all map layer types.
The QgsLayerDefinition class holds generic methods for loading/exporting QLR files.
Class used to work with layer dependencies stored in a XML project or layer definition file...
bool hasCycle() const
Whether some cyclic dependency has been detected.
This class is a base class for nodes in a layer tree.
Reads and writes project states.
bool hasMissingDependency() const
Whether some dependency is missing.
QVector< QDomNode > sortedLayerNodes() const
Gets the layer nodes in an order where they can be loaded incrementally without dependency break...
QStringList sortedLayerIds() const
Gets the layer IDs in an order where they can be loaded incrementally without dependency break...