QGIS API Documentation 3.99.0-Master (2fe06baccd8)
Loading...
Searching...
No Matches
qgswmsrequest.cpp
Go to the documentation of this file.
1/***************************************************************************
2 qgswmsrequest.cpp
3
4 Define request class for getting request contents for WMS service
5 -------------------
6 begin : 2021-02-10
7 copyright : (C) 2021 by Paul Blottiere
9 ***************************************************************************/
10
11/***************************************************************************
12 * *
13 * This program is free software; you can redistribute it and/or modify *
14 * it under the terms of the GNU General Public License as published by *
15 * the Free Software Foundation; either version 2 of the License, or *
16 * (at your option) any later version. *
17 * *
18 ***************************************************************************/
19
20#include "qgswmsrequest.h"
21
22#include "moc_qgswmsrequest.cpp"
23
24namespace QgsWms
25{
27 : QgsServerRequest( other )
28 {
29 init();
30 }
31
33 {
34 return mWmsParams;
35 }
36
37 void QgsWmsRequest::setParameter( const QString &key, const QString &value )
38 {
40 init();
41 }
42
43 void QgsWmsRequest::removeParameter( const QString &key )
44 {
46 init();
47 }
48
49 void QgsWmsRequest::setUrl( const QUrl &url )
50 {
52 init();
53 }
54
55 void QgsWmsRequest::init()
56 {
57 mWmsParams = QgsWmsParameters( serverParameters() );
58 }
59} // namespace QgsWms
QgsServerParameters serverParameters() const
Returns parameters.
virtual void setParameter(const QString &key, const QString &value)
Set a parameter.
QgsServerRequest()=default
virtual void setUrl(const QUrl &url)
Set the request url.
QUrl url() const
Returns the request URL as seen by QGIS server.
virtual void removeParameter(const QString &key)
Remove a parameter.
Provides an interface to retrieve and manipulate WMS parameters received from the client.
void setParameter(const QString &key, const QString &value) override
Set a parameter.
const QgsWmsParameters & wmsParameters() const
Returns the parameters interpreted for the WMS service.
void removeParameter(const QString &key) override
Remove a parameter.
void setUrl(const QUrl &url) override
Set the request url.
QgsWmsRequest(const QgsServerRequest &other)
Copy constructor.
Median cut implementation.