19 #ifndef QGSMAPLAYERREGISTRY_H 20 #define QGSMAPLAYERREGISTRY_H 24 #include <QStringList> 87 for ( ; layerIt != mMapLayers.constEnd(); ++layerIt )
89 T tLayer = qobject_cast<T>( layerIt.
value() );
124 bool addToLegend =
true,
125 bool takeOwnership =
true );
154 QgsMapLayer* addMapLayer(
QgsMapLayer * theMapLayer,
bool addToLegend =
true,
bool takeOwnership =
true );
171 void removeMapLayers(
const QStringList& theLayerIds );
203 void removeMapLayer(
const QString& theLayerId );
230 void removeAllMapLayers();
238 Q_DECL_DEPRECATED
void clearAllLayerCaches() {}
246 void reloadAllLayers();
258 void layersWillBeRemoved(
const QStringList& theLayerIds );
279 void layerWillBeRemoved(
const QString& theLayerId );
299 void layersRemoved(
const QStringList& theLayerIds );
310 void layerRemoved(
const QString& theLayerId );
365 void onMapLayerDeleted(
QObject* obj );
374 #endif //QGSMAPLAYERREGISTRY_H Base class for all map layer types.
QVector< T > layers() const
Returns a list of registered map layers with a specified layer type.
This class tracks map layers that are currently loaded and provides various methods to retrieve match...
virtual void connectNotify(const char *signal)