RAII class to restore layer filters on destruction.
More...
#include <qgsfilterrestorer.h>
RAII class to restore layer filters on destruction.
- Since
- QGIS 3.0
Definition at line 36 of file qgsfilterrestorer.h.
◆ QgsOWSServerFilterRestorer() [1/2]
QgsOWSServerFilterRestorer::QgsOWSServerFilterRestorer |
( |
| ) |
|
|
default |
◆ ~QgsOWSServerFilterRestorer()
QgsOWSServerFilterRestorer::~QgsOWSServerFilterRestorer |
( |
| ) |
|
|
inline |
Destructor. When object is destroyed all original layer filters will be restored.
Definition at line 46 of file qgsfilterrestorer.h.
◆ QgsOWSServerFilterRestorer() [2/2]
◆ applyAccessControlLayerFilters() [1/2]
static void QgsOWSServerFilterRestorer::applyAccessControlLayerFilters |
( |
const QgsAccessControl * |
accessControl, |
|
|
QgsMapLayer * |
mapLayer, |
|
|
QHash< QgsMapLayer *, QString > & |
originalLayerFilters |
|
) |
| |
|
static |
Apply filter from AccessControl.
◆ applyAccessControlLayerFilters() [2/2]
static void QgsOWSServerFilterRestorer::applyAccessControlLayerFilters |
( |
const QgsAccessControl * |
accessControl, |
|
|
QgsMapLayer * |
mapLayer |
|
) |
| |
|
static |
Applies filters from access control on layer.
- Parameters
-
accessControl | The access control instance |
mapLayer | The layer on which the filter has to be applied |
- Since
- QGIS 3.0
◆ operator=()
◆ originalFilters()
QHash<QgsMapLayer *, QString>& QgsOWSServerFilterRestorer::originalFilters |
( |
| ) |
|
|
inline |
Returns a reference to the object's hash of layers to original subsetString filters.
Original layer subsetString filters MUST be inserted into this hash before modifying them.
Definition at line 62 of file qgsfilterrestorer.h.
◆ restoreLayerFilters()
void QgsOWSServerFilterRestorer::restoreLayerFilters |
( |
const QHash< QgsMapLayer *, QString > & |
filterMap | ) |
|
Apply filter from AccessControal.
Restore layer filter as original
Definition at line 79 of file qgsfilterrestorer.cpp.
The documentation for this class was generated from the following files: