16#ifndef QGSPROJECTSTOREDOBJECTMANAGER_H
17#define QGSPROJECTSTOREDOBJECTMANAGER_H
T * objectByName(const QString &name) const
Returns the object with a matching name, or nullptr if no matching objects were found.
QList< T * > objects() const
Returns the list of objects contained within the manager.
QList< T * > mObjects
Attached objects, owned by the manager.
bool addObject(T *object)
Adds an object to the manager.
bool removeObject(T *object)
Removes an object from the manager.
QgsAbstractProjectStoredObjectManager(QgsProject *project=nullptr)
Constructor for QgsAbstractProjectStoredObjectManager, for objects attached to the specified project.
virtual void setupObjectConnections(T *object)
Sets up additional connections to an object, called when the object is first added to the manager.
void clearObjects()
Removes and deletes all objects from the manager.
void objectAdded(const QString &name)
Emitted when an object has been added to the manager.
void objectRemoved(const QString &name)
Emitted when an object was removed from the manager.
QgsProject * mProject
Associated project.
void objectAboutToBeAdded(const QString &name)
Emitted when an object is about to be added to the manager.
void objectAboutToBeRemoved(const QString &name)
Emitted when an object is about to be removed from the manager.
void markProjectDirty()
Marks the project as dirty.
QgsProjectStoredObjectManagerBase(QgsProject *project=nullptr)
Constructor for QgsProjectStoredObjectManagerBase, for objects attached to the specified project.
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...