35 response.
setHeader( QStringLiteral(
"Content-Type" ), QStringLiteral(
"text/xml; charset=utf-8" ) );
36 response.
write( doc.toByteArray() );
43 Q_UNUSED( serverIface );
50 QFileInfo xsdFileInfo( resourcesDir, QStringLiteral(
"schemaExtension.xsd" ) );
52 if ( !xsdFileInfo.exists() )
59 QString xsdFilePath = xsdFileInfo.absoluteFilePath();
60 QFile xsdFile( xsdFilePath );
61 if ( !xsdFile.exists() )
68 if ( !xsdFile.open( QIODevice::ReadOnly ) )
77 if ( !xsdDoc.setContent( &xsdFile,
true, &errorMsg, &line, &column ) )
80 QStringLiteral(
"': parse error %1 at row %2, column %3" ).arg( errorMsg ).arg( line ).arg( column ),
virtual void setHeader(const QString &key, const QString &value)=0
Set Header entry Add Header entry to the response Note that it is usually an error to set Header afte...
virtual void write(const QString &data)
Write string This is a convenient method that will write directly to the underlying I/O device...
QDomDocument getSchemaExtension(QgsServerInterface *serverIface, const QString &version, const QgsServerRequest &request)
Returns the schemaExtension for WMS 1.3.0 capabilities.
static void logMessage(const QString &message, const QString &tag=QString(), Qgis::MessageLevel level=Qgis::Warning, bool notifyUser=true)
Adds a message to the log instance (and creates it if necessary).
Median cut implementation.
QgsServerRequest Class defining request interface passed to services QgsService::executeRequest() met...
QgsServerInterface Class defining interfaces exposed by QGIS Server and made available to plugins...
void writeGetSchemaExtension(QgsServerInterface *serverIface, const QString &version, const QgsServerRequest &request, QgsServerResponse &response)
Output GetSchemaExtension response.
QgsServerResponse Class defining response interface passed to services QgsService::executeRequest() m...
static QString serverResourcesPath()
Returns the path to the server resources directory.
QgsServerRequest::Parameters parameters() const
Returns a map of query parameters with keys converted to uppercase.
QMap< QString, QString > Parameters