QGIS API Documentation  3.0.2-Girona (307d082)
Public Member Functions | List of all members
QgsServerInterface Class Referenceabstract

QgsServerInterface Class defining interfaces exposed by QGIS Server and made available to plugins. More...

#include <qgsserverinterface.h>

Public Member Functions

 QgsServerInterface ()
 Constructor. More...
 
virtual ~QgsServerInterface ()=default
 
virtual QgsAccessControl * accessControls () const =0
 Gets the registered access control filters. More...
 
virtual QgsCapabilitiesCachecapabilitiesCache ()=0
 Get pointer to the capabiblities cache. More...
 
virtual void clearRequestHandler ()=0
 Clear the request handler. More...
 
virtual QString configFilePath ()=0
 Return the configuration file path. More...
 
virtual QgsServerFiltersMap filters ()=0
 Return the list of current QgsServerFilter. More...
 
virtual QString getEnv (const QString &name) const =0
 Return an enrironment variable, used to pass environment variables to Python. More...
 
virtual void registerAccessControl (QgsAccessControlFilter *accessControl, int priority=0)=0
 Register an access control filter. More...
 
virtual void registerFilter (QgsServerFilter *filter, int priority=0)=0
 Register a QgsServerFilter. More...
 
virtual void removeConfigCacheEntry (const QString &path)=0
 Remove entry from config cache. More...
 
virtual void removeProjectLayers (const QString &path)=0
 Remove entries from layer cache. More...
 
virtual QgsRequestHandlerrequestHandler ()=0
 Get pointer to the request handler. More...
 
virtual QgsServerSettings * serverSettings ()=0
 Return the server settings. More...
 
virtual QgsServiceRegistryserviceRegistry ()=0
 Return the service registry. More...
 
virtual void setConfigFilePath (const QString &configFilePath)=0
 Set the configuration file path. More...
 
virtual void setFilters (QgsServerFiltersMap *filters)=0
 Set the filters map. More...
 
virtual void setRequestHandler (QgsRequestHandler *requestHandler)=0
 Set the request handler. More...
 

Detailed Description

QgsServerInterface Class defining interfaces exposed by QGIS Server and made available to plugins.

This class provides methods to access the request handler and the capabilities cache. A method to read the environment variables set in the main FCGI loop is also available. Plugins can add listeners (instances of QgsServerFilter) with a certain priority through the registerFilter( QgsServerFilter* , int) method.

Definition at line 57 of file qgsserverinterface.h.

Constructor & Destructor Documentation

◆ QgsServerInterface()

QgsServerInterface::QgsServerInterface ( )

Constructor.

◆ ~QgsServerInterface()

virtual QgsServerInterface::~QgsServerInterface ( )
virtualdefault

Member Function Documentation

◆ accessControls()

virtual QgsAccessControl* QgsServerInterface::accessControls ( ) const
pure virtual

Gets the registered access control filters.

◆ capabilitiesCache()

virtual QgsCapabilitiesCache* QgsServerInterface::capabilitiesCache ( )
pure virtual

Get pointer to the capabiblities cache.

Returns
QgsCapabilitiesCache

◆ clearRequestHandler()

virtual void QgsServerInterface::clearRequestHandler ( )
pure virtual

Clear the request handler.

Note
not available in Python bindings

◆ configFilePath()

virtual QString QgsServerInterface::configFilePath ( )
pure virtual

Return the configuration file path.

Returns
QString containing the configuration file path

◆ filters()

virtual QgsServerFiltersMap QgsServerInterface::filters ( )
pure virtual

Return the list of current QgsServerFilter.

Returns
QgsServerFiltersMap list of QgsServerFilter

◆ getEnv()

virtual QString QgsServerInterface::getEnv ( const QString &  name) const
pure virtual

Return an enrironment variable, used to pass environment variables to Python.

◆ registerAccessControl()

virtual void QgsServerInterface::registerAccessControl ( QgsAccessControlFilter accessControl,
int  priority = 0 
)
pure virtual

Register an access control filter.

Parameters
accessControlthe access control to register
prioritythe priority used to order them

◆ registerFilter()

virtual void QgsServerInterface::registerFilter ( QgsServerFilter filter,
int  priority = 0 
)
pure virtual

Register a QgsServerFilter.

Parameters
filterthe QgsServerFilter to add
priorityan optional priority for the filter order

◆ removeConfigCacheEntry()

virtual void QgsServerInterface::removeConfigCacheEntry ( const QString &  path)
pure virtual

Remove entry from config cache.

Parameters
paththe path of the file to remove

◆ removeProjectLayers()

virtual void QgsServerInterface::removeProjectLayers ( const QString &  path)
pure virtual

Remove entries from layer cache.

Parameters
paththe path of the project which own the layers to be removed

◆ requestHandler()

virtual QgsRequestHandler* QgsServerInterface::requestHandler ( )
pure virtual

Get pointer to the request handler.

Returns
QgsRequestHandler

◆ serverSettings()

virtual QgsServerSettings* QgsServerInterface::serverSettings ( )
pure virtual

Return the server settings.

Returns
QgsServerSettings
Note
not available in Python bindings

◆ serviceRegistry()

virtual QgsServiceRegistry* QgsServerInterface::serviceRegistry ( )
pure virtual

Return the service registry.

Returns
QgsServiceResgistry

◆ setConfigFilePath()

virtual void QgsServerInterface::setConfigFilePath ( const QString &  configFilePath)
pure virtual

Set the configuration file path.

Parameters
configFilePathQString with the configuration file path

◆ setFilters()

virtual void QgsServerInterface::setFilters ( QgsServerFiltersMap filters)
pure virtual

Set the filters map.

Parameters
filtersthe QgsServerFiltersMap

◆ setRequestHandler()

virtual void QgsServerInterface::setRequestHandler ( QgsRequestHandler requestHandler)
pure virtual

Set the request handler.

Parameters
requestHandlerrequest handler
Note
not available in Python bindings

The documentation for this class was generated from the following file: