mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-28 00:17:30 -05:00
Allow to override the default behavior in case of bad layers (which is to invalidate the whole project). When set to TRUE, the bad layers are skipped and the project is considered available. Followup #8922
67 lines
2.0 KiB
Plaintext
67 lines
2.0 KiB
Plaintext
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/server/qgsconfigcache.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class QgsConfigCache : QObject
|
|
{
|
|
%Docstring
|
|
Cache for server configuration.
|
|
|
|
.. versionadded:: 2.8
|
|
%End
|
|
|
|
%TypeHeaderCode
|
|
#include "qgsconfigcache.h"
|
|
%End
|
|
public:
|
|
|
|
static QgsConfigCache *instance();
|
|
%Docstring
|
|
Returns the current instance.
|
|
%End
|
|
|
|
void removeEntry( const QString &path );
|
|
%Docstring
|
|
Removes an entry from cache.
|
|
|
|
:param path: The path of the project
|
|
%End
|
|
|
|
const QgsProject *project( const QString &path, QgsServerSettings *settings = 0 );
|
|
%Docstring
|
|
If the project is not cached yet, then the project is read from the
|
|
path. If the project is not available, then ``None`` is returned.
|
|
If the project contains any bad layer it is considered unavailable
|
|
unless the server configuration variable QGIS_SERVER_IGNORE_BAD_LAYERS
|
|
passed in the optional settings argument is set to ``True`` (the default
|
|
value is ``False``).
|
|
|
|
:param path: the filename of the QGIS project
|
|
:param settings: QGIS server settings
|
|
|
|
:return: the project or ``None`` if an error happened
|
|
|
|
.. versionadded:: 3.0
|
|
%End
|
|
|
|
private:
|
|
QgsConfigCache();
|
|
};
|
|
|
|
/************************************************************************
|
|
* This file has been generated automatically from *
|
|
* *
|
|
* src/server/qgsconfigcache.h *
|
|
* *
|
|
* Do not edit manually ! Edit header and run scripts/sipify.pl again *
|
|
************************************************************************/
|