16 #ifndef QGSPROJECTSTORAGE_H
17 #define QGSPROJECTSTORAGE_H
19 #include "qgis_core.h"
60 virtual QString
type() = 0;
91 virtual bool renameProject(
const QString &uri,
const QString &uriNew ) { Q_UNUSED( uri ) Q_UNUSED( uriNew );
return false; }
105 virtual QString filePath(
const QString &uri );
Abstract interface for project storage - to be implemented by various backends and registered in QgsP...
virtual Q_DECL_DEPRECATED QString showSaveGui()
Opens GUI to allow user to select where a project should be saved (GUI specific to this storage type)...
virtual bool renameProject(const QString &uri, const QString &uriNew)
Rename an existing project at the given URI to a different URI.
virtual bool writeProject(const QString &uri, QIODevice *device, QgsReadWriteContext &context)=0
Writes project file content stored in given device (could be e.g.
virtual Q_DECL_DEPRECATED QString showLoadGui()
Opens GUI to allow user to select a project to be loaded (GUI specific to this storage type).
virtual QStringList listProjects(const QString &uri)=0
Returns list of all projects for given URI (specific to each storage backend)
virtual ~QgsProjectStorage()=default
virtual QString type()=0
Unique identifier of the project storage type.
virtual bool readProject(const QString &uri, QIODevice *device, QgsReadWriteContext &context)=0
Reads project file content stored in the backend at the specified URI to the given device (could be e...
virtual bool removeProject(const QString &uri)=0
Removes an existing project at the given URI.
virtual bool readProjectStorageMetadata(const QString &uri, QgsProjectStorage::Metadata &metadata)
Reads project metadata (e.g.
virtual Q_DECL_DEPRECATED QString visibleName()
Returns human-readable name of the storage.
The class is used as a container of context for various read/write operations on other objects.