Class: QgsServerStaticHandler

class qgis.server.QgsServerStaticHandler(pathRegExp: str = '', staticPathSuffix: str = '')

Bases: qgis._server.QgsServerOgcApiHandler

Creates QgsServerStaticHandler

Parameters
  • pathRegExp – optional regular expression to capture static file names, defaults to “/static/(?<staticFilePath>.*)$”, note that the file path is captured in a named group “staticFilePath”

  • staticPathSuffix – optional path suffix to use when static files are stored in a subdirectory of the default staticPath()

QgsServerStaticHandler(QgsServerStaticHandler)

The QgsServerStaticHandler class serves static files from the static path (resources/server/api/wfs3/static)

Methods

description

rtype

object

handleRequest

param context

linkTitle

rtype

object

linkType

rtype

QgsServerOgcApi.Rel

operationId

rtype

object

path

rtype

QRegularExpression

setContentTypes

Set the content types to contentTypes

summary

rtype

object

description(self)object
Return type

object

handleRequest(self, context: QgsServerApiContext)
Parameters

context (QgsServerApiContext) –

linkTitle(self)object
Return type

object

linkType(self)QgsServerOgcApi.Rel
Return type

QgsServerOgcApi.Rel

operationId(self)object
Return type

object

path(self)QRegularExpression
Return type

QRegularExpression

setContentTypes(self, contentTypes: Iterable[int])

Set the content types to contentTypes

summary(self)object
Return type

object