34 mParams.
load( QUrlQuery( url ) );
39 return mHeaders.value( name );
45 mHeaders.insert( name, value );
56 mHeaders.remove( name );
81 return mParams.
toMap();
96 mParams.
add( key, value );
102 return mParams.
value( key );
108 mUrl.setQuery( mParams.
urlQuery() );
115 mParams.
load( QUrlQuery( mUrl ) );
QMap< QString, QString > toMap() const
Returns all parameters in a map.
QgsServerRequest()=default
Constructor.
void setMethod(QgsServerRequest::Method method)
Set the request method.
void setParameter(const QString &key, const QString &value)
Set a parameter.
QString header(const QString &name) const
Returns the header value.
QString value(const QString &key) const
Returns the value of a parameter.
void remove(const QString &key)
Removes a parameter.
void load(const QUrlQuery &query)
Loads new parameters.
void setUrl(const QUrl &url)
Set the request url.
Method
HTTP Method (or equivalent) used for the request.
QUrl originalUrl() const
Returns the request url as seen by the web server, by default this is equal to the url seen by QGIS s...
QMap< QString, QString > Headers
virtual QByteArray data() const
Returns post/put data Check for QByteArray::isNull() to check if data is available.
QMap< QString, QString > headers() const
Returns the header map.
QgsServerRequest::Parameters parameters() const
Returns a map of query parameters with keys converted to uppercase.
QUrlQuery urlQuery() const
Returns a url query with underlying parameters.
void setHeader(const QString &name, const QString &value)
Set an header.
QgsServerRequest Class defining request interface passed to services QgsService::executeRequest() met...
void add(const QString &key, const QString &value)
Adds a parameter.
void removeHeader(const QString &name)
Remove an header.
QgsServerParameters provides an interface to retrieve and manipulate global parameters received from ...
QgsServerParameters serverParameters() const
Returns parameters.
void removeParameter(const QString &key)
Remove a parameter.
QgsServerRequest::Method method() const
void setOriginalUrl(const QUrl &url)
Set the request original url (the request url as seen by the web server)
void clear()
Removes all parameters.
QString parameter(const QString &key) const
Gets a parameter value.