18#ifndef QGSFILTERRESTORER_H
19#define QGSFILTERRESTORER_H
24#include "qgis_server.h"
48 restoreLayerFilters( mOriginalLayerFilters );
56 void restoreLayerFilters(
const QHash<QgsMapLayer *, QString> &filterMap );
62 QHash<QgsMapLayer *, QString> &
originalFilters() {
return mOriginalLayerFilters; }
67 QHash<QgsMapLayer *, QString> &originalLayerFilters );
78 QHash<QgsMapLayer *, QString> mOriginalLayerFilters;
A helper class that centralizes restrictions given by all the access control filter plugins.
Base class for all map layer types.
RAII class to restore layer filters on destruction.
QHash< QgsMapLayer *, QString > & originalFilters()
Returns a reference to the object's hash of layers to original subsetString filters.
QgsOWSServerFilterRestorer(const QgsOWSServerFilterRestorer &rh)=delete
QgsOWSServerFilterRestorer cannot be copied.
~QgsOWSServerFilterRestorer()
Destructor. When object is destroyed all original layer filters will be restored.
static void applyAccessControlLayerFilters(const QgsAccessControl *accessControl, QgsMapLayer *mapLayer, QHash< QgsMapLayer *, QString > &originalLayerFilters)
Apply filter from AccessControl.
QgsOWSServerFilterRestorer & operator=(const QgsOWSServerFilterRestorer &rh)=delete
QgsOWSServerFilterRestorer cannot be copied.
QgsOWSServerFilterRestorer()=default
Default constructor for QgsOWSServerFilterRestorer.
static void applyAccessControlLayerFilters(const QgsAccessControl *accessControl, QgsMapLayer *mapLayer)
Applies filters from access control on layer.