QGIS API Documentation
3.16.0-Hannover (43b64b13f3)
|
Go to the documentation of this file.
21 #ifndef QGSSERVERAPIUTILS_H
22 #define QGSSERVERAPIUTILS_H
24 #include "qgis_server.h"
34 #ifdef HAVE_SERVER_PYTHON_PLUGINS
44 #include "nlohmann/json_fwd.hpp"
45 using namespace nlohmann;
69 static QList< QgsVectorLayerServerProperties::WmsDimensionInfo > temporalDimensions(
const QgsVectorLayer *layer );
89 template<
typename T,
class T2>
static T parseTemporalInterval(
const QString &interval )
SIP_SKIP;
159 static const QVector<QgsVectorLayer *> publishedWfsLayers(
const QgsServerApiContext &context );
172 template <
typename T>
175 #ifdef HAVE_SERVER_PYTHON_PLUGINS
183 const auto constLayers { project->
layers<T>() };
184 for (
const auto &layer : constLayers )
190 #ifdef HAVE_SERVER_PYTHON_PLUGINS
196 result.push_back( layer );
209 static QString sanitizedFieldValue(
const QString &value );
215 static QStringList publishedCrsList(
const QgsProject *project );
226 static QString appendMapParameter(
const QString &path,
const QUrl &requestUrl );
229 #endif // QGSSERVERAPIUTILS_H
QVector< T > layers() const
Returns a list of registered map layers with a specified layer type.
The QgsServerApiContext class encapsulates the resources for a particular client request: the request...
const QgsCoordinateReferenceSystem & crs
static const QVector< T > publishedWfsLayers(const QgsServerApiContext &context)
Returns the list of layers of type T accessible to the WFS service for a given project.
bool layerReadPermission(const QgsMapLayer *layer) const
Returns the layer read right.
virtual QgsAccessControl * accessControls() const =0
Gets the registered access control filters.
A rectangle specified with double values.
Encapsulates a QGIS project, including sets of map layers and their styles, layouts,...
SERVER_EXPORT QStringList wfsLayerIds(const QgsProject &project)
Returns the Layer ids list defined in a QGIS project as published in WFS.
const QgsProject * project() const
Returns the (possibly NULL) project.
The QgsServerApiUtils class contains helper functions to handle common API operations.
QString id() const
Returns the layer's unique ID, which is used to access this layer from QgsProject.
QgsServerInterface * serverInterface() const
Returns the server interface.
This class represents a coordinate reference system (CRS).
A helper class that centralizes restrictions given by all the access control filter plugins.
Represents a vector layer which manages a vector based data sets.
Class for parsing and evaluation of expressions (formerly called "search strings").
QgsRectangle parseBbox(const QString &bboxStr)
Parse bounding box.
Bad request error API exception.