QGIS API Documentation 4.1.0-Master (3fcefe620d1)
Loading...
Searching...
No Matches
qgswmsparameters.h
Go to the documentation of this file.
1/***************************************************************************
2 qgswmsparameters.h
3 ------------------
4 begin : March 17, 2017
5 copyright : (C) 2017 by Paul Blottiere
6 email : paul dot blottiere at oslandia dot com
7 ***************************************************************************/
8
9/***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
17
18#ifndef QGSWMSPARAMETERS_H
19#define QGSWMSPARAMETERS_H
20
21#include "qgslegendsettings.h"
22#include "qgsogcutils.h"
23#include "qgsprojectversion.h"
24#include "qgsrectangle.h"
25#include "qgsserverparameters.h"
26
27#include <QColor>
28#include <QMap>
29#include <QMetaEnum>
30
31namespace QgsWms
32{
47
49 {
50 QString mNickname; // name, id or short name
51 int mOpacity = -1;
52 QList<QgsWmsParametersFilter> mFilter; // list of filter
53 QStringList mSelection; // list of string fid
54 QString mStyle;
55 QString mExternalUri;
56 };
57
59 {
60 QString mName;
61 QString mUri;
62 };
63
65 {
66 QString mName;
68 QString mSld;
69 QString mLabel;
70 QColor mColor;
71 int mSize = 0;
72 int mWeight = 0;
73 QString mFont;
74 float mBufferSize = 0;
76 QColor mFrameBackgroundColor = Qt::white;
77 QColor mFrameOutlineColor = Qt::black;
79 float mFrameSize = 0;
80 double mLabelRotation = 0;
81 double mLabelDistance = 2; //label distance from feature in mm
82 QString mHali; //horizontal alignment
83 QString mVali; //vertical alignment
84 };
85
87 {
88 int mId = 0; // composer map id
89 bool mHasExtent = false; // does the request contains extent for this composer map
90 QgsRectangle mExtent; // the request extent for this composer map
91 float mScale = -1;
92 float mRotation = 0;
93 float mGridX = 0;
94 float mGridY = 0;
95 QList<QgsWmsParametersLayer> mLayers; // list of layers for this composer map
96 QList<QgsWmsParametersHighlightLayer> mHighlightLayers; // list of highlight layers for this composer map
97 };
98
106 {
107 Q_GADGET
108
109 public:
111 enum Name
112 {
200 };
201 Q_ENUM( Name )
202
203
209 QgsWmsParameter( const QgsWmsParameter::Name name = QgsWmsParameter::UNKNOWN, const QMetaType::Type type = QMetaType::Type::QString, const QVariant defaultValue = QVariant( "" ) );
210
214 ~QgsWmsParameter() override = default;
215
219 bool isValid() const override;
220
229 QStringList toStyleList( const char delimiter = ',', bool skipEmptyParts = false ) const;
230
238 QList<QgsGeometry> toGeomList( const char delimiter = ',', bool skipEmptyParts = true ) const;
239
247 QList<int> toIntList( const char delimiter = ',', bool skipEmptyParts = true ) const;
248
256 QList<double> toDoubleList( const char delimiter = ',', bool skipEmptyParts = true ) const;
257
265 QList<QColor> toColorList( const char delimiter = ',', bool skipEmptyParts = true ) const;
266
273
279 int toInt() const;
280
286 double toDouble() const;
287
293 QColor toColor() const;
294
301 QUrl toUrl() const;
302
309 QString loadUrl() const;
310
315 void raiseError() const;
316
321 QString name() const;
322
326 static QString name( const QgsWmsParameter::Name );
327
332 static QgsWmsParameter::Name name( const QString &name );
333
335
337 int mMapId = -1;
338 };
339
346 {
347 Q_GADGET
348
349 public:
364 Q_ENUM( Format )
365
366
378 Q_ENUM( DxfFormatOption )
379
397 Q_ENUM( PdfFormatOption )
398
399
403 QgsWmsParameters( const QgsServerParameters &parameters );
404
409
410 ~QgsWmsParameters() override = default;
411
417
422 void set( QgsWmsParameter::Name name, const QVariant &value );
423
427 void dump() const;
428
433 QString crs() const;
434
439 QString width() const;
440
448 int widthAsInt() const;
449
454 QString height() const;
455
463 int heightAsInt() const;
464
470 bool showRuleDetailsAsBool() const;
471
477 QString srcWidth() const;
478
487 int srcWidthAsInt() const;
488
494 QString srcHeight() const;
495
504 int srcHeightAsInt() const;
505
511
516 bool versionIsValid( const QString version ) const;
517
522 QString bbox() const;
523
531
536 QString sldBody() const;
537
542 QStringList selections() const;
543
548 QStringList filters() const;
549
554 QString filterGeom() const;
555
560 QStringList opacities() const;
561
569 QList<int> opacitiesAsInt() const;
570
575 QStringList allLayersNickname() const;
576
581 QStringList queryLayersNickname() const;
582
587 QStringList allStyles() const;
588
593 QList<QgsWmsParametersLayer> layersParameters() const;
594
600 QString polygonTolerance() const;
601
607 QString lineTolerance() const;
608
614 QString pointTolerance() const;
615
621 int polygonToleranceAsInt() const;
622
628 int lineToleranceAsInt() const;
629
635 int pointToleranceAsInt() const;
636
641 QString formatAsString() const;
642
647 static QString formatAsString( Format format );
648
654 Format format() const;
655
660 QString infoFormatAsString() const;
661
666 bool infoFormatIsImage() const;
667
673 QString imageQuality() const;
674
680 int imageQualityAsInt() const;
681
687 QString tiled() const;
688
694 bool tiledAsBool() const;
695
699 bool addLayerGroups() const;
700
706 Format infoFormat() const;
707
713 int infoFormatVersion() const;
714
719 QString i() const;
720
728 int iAsInt() const;
729
734 QString j() const;
735
743 int jAsInt() const;
744
749 QString x() const;
750
758 int xAsInt() const;
759
764 QString y() const;
765
773 int yAsInt() const;
774
779 QString rule() const;
780
785 QString ruleLabel() const;
786
793 bool ruleLabelAsBool() const;
794
799 QString showFeatureCount() const;
800
807 bool showFeatureCountAsBool() const;
808
813 QString featureCount() const;
814
821 int featureCountAsInt() const;
822
827 QString scale() const;
828
835 double scaleAsDouble() const;
836
841 QString boxSpace() const;
842
849 double boxSpaceAsDouble() const;
850
855 QString layerSpace() const;
856
863 double layerSpaceAsDouble() const;
864
869 QString layerTitleSpace() const;
870
877 double layerTitleSpaceAsDouble() const;
878
883 QString symbolSpace() const;
884
891 double symbolSpaceAsDouble() const;
892
897 QString iconLabelSpace() const;
898
905 double iconLabelSpaceAsDouble() const;
906
911 QString symbolWidth() const;
912
919 double symbolWidthAsDouble() const;
920
925 QString symbolHeight() const;
926
933 double symbolHeightAsDouble() const;
934
940 QFont layerFont() const;
941
946 QString layerFontFamily() const;
947
952 QString layerFontBold() const;
953
960 bool layerFontBoldAsBool() const;
961
966 QString layerFontItalic() const;
967
974 bool layerFontItalicAsBool() const;
975
980 QString layerFontSize() const;
981
988 double layerFontSizeAsDouble() const;
989
994 QString layerFontColor() const;
995
1002 QColor layerFontColorAsColor() const;
1003
1009 QFont itemFont() const;
1010
1015 QString itemFontFamily() const;
1016
1021 QString itemFontBold() const;
1022
1029 bool itemFontBoldAsBool() const;
1030
1035 QString itemFontItalic() const;
1036
1043 bool itemFontItalicAsBool() const;
1044
1049 QString itemFontSize() const;
1050
1057 double itemFontSizeAsDouble() const;
1058
1063 QString itemFontColor() const;
1064
1071 QColor itemFontColorAsColor() const;
1072
1077 QString layerTitle() const;
1078
1085 bool layerTitleAsBool() const;
1086
1092
1097 QList<QgsWmsParametersHighlightLayer> highlightLayersParameters() const;
1098
1103 QList<QgsWmsParametersExternalLayer> externalLayersParameters() const;
1104
1109 QStringList highlightGeom() const;
1110
1117 QList<QgsGeometry> highlightGeomAsGeom() const;
1118
1123 QStringList highlightSymbol() const;
1124
1129 QStringList highlightLabelString() const;
1130
1135 QStringList highlightLabelColor() const;
1136
1143 QList<QColor> highlightLabelColorAsColor() const;
1144
1149 QStringList highlightLabelSize() const;
1150
1157 QList<int> highlightLabelSizeAsInt() const;
1158
1163 QStringList highlightLabelWeight() const;
1164
1171 QList<int> highlightLabelWeightAsInt() const;
1172
1177 QStringList highlightLabelFont() const;
1178
1183 QStringList highlightLabelBufferSize() const;
1184
1191 QList<double> highlightLabelBufferSizeAsFloat() const;
1192
1197 QStringList highlightLabelFrameBackgroundColor() const;
1198
1205 QList<QColor> highlightLabelFrameBackgroundColorAsColor() const;
1206
1211 QStringList highlightLabelFrameOutlineColor() const;
1212
1219 QList<QColor> highlightLabelFrameOutlineColorAsColor() const;
1220
1225 QStringList highlightLabelFrameOutlineWidth() const;
1226
1233 QList<double> highlightLabelFrameOutlineWidthAsFloat() const;
1234
1239 QStringList highlightLabelFrameSize() const;
1240
1247 QList<double> highlightLabelFrameSizeAsFloat() const;
1248
1253 QStringList highlightLabelBufferColor() const;
1254
1261 QList<QColor> highlightLabelBufferColorAsColor() const;
1262
1267 QList<double> highlightLabelRotation() const;
1268
1273 QList<double> highlightLabelDistance() const;
1274
1279 QStringList highlightLabelHorizontalAlignment() const;
1280
1285 QStringList highlightLabelVerticalAlignment() const;
1286
1291 QString wmsPrecision() const;
1292
1300 int wmsPrecisionAsInt() const;
1301
1306 QString transparent() const;
1307
1315 bool transparentAsBool() const;
1316
1321 QString backgroundColor() const;
1322
1330 QColor backgroundColorAsColor() const;
1331
1336 QString dpi() const;
1337
1345 double dpiAsDouble() const;
1346
1351 QString composerTemplate() const;
1352
1363
1369 QString externalWMSUri( const QString &id ) const;
1370
1375 bool withGeometry() const;
1376
1382 QString withMapTipAsString() const;
1383
1388 bool withMapTip() const;
1389
1396 bool htmlInfoOnlyMapTip() const;
1397
1403 bool withDisplayName() const;
1404
1409 QString wmtver() const;
1410
1418 QString layoutParameter( const QString &id, bool &ok ) const;
1419
1425 QStringList atlasPk() const;
1426
1431 QStringList dxfLayerAttributes() const;
1432
1437 bool dxfUseLayerTitleAsName() const;
1438
1443 double dxfScale() const;
1444
1450
1455 QString dxfCodec() const;
1456
1461 QMap<QString, QString> dimensionValues() const;
1462
1469 bool noMText() const;
1470
1477 bool isForce2D() const;
1478
1484 bool exportLinesWithZeroWidth() const;
1485
1490 bool writeGeospatialPdf() const;
1491
1496 bool pdfForceVectorOutput() const;
1497
1502 bool pdfAppendGeoreference() const;
1503
1508 bool pdfSimplifyGeometries() const;
1509
1514 bool pdfExportMetadata() const;
1515
1521
1526 bool pdfLosslessImageCompression() const;
1527
1532 bool pdfDisableTiledRasterRendering() const;
1533
1539
1545 Q_DECL_DEPRECATED bool pdfUseOgcBestPracticeFormatGeoreferencing() const;
1546
1551 QStringList pdfExportMapThemes() const;
1552
1557 QVector<qreal> pdfPredefinedMapScales() const;
1558
1559 QString version() const override;
1560
1561 QString request() const override;
1562
1568 template<typename T> QMap<T, QString> formatOptions() const
1569 {
1570 QMap<T, QString> options;
1571 const QMetaEnum metaEnum( QMetaEnum::fromType<T>() );
1572 const QStringList opts = mWmsParameters.value( QgsWmsParameter::FORMAT_OPTIONS ).toStringList( ';' );
1573
1574 for ( auto it = opts.constBegin(); it != opts.constEnd(); ++it )
1575 {
1576 const int equalIdx = it->indexOf( ':' );
1577 if ( equalIdx > 0 && equalIdx < ( it->length() - 1 ) )
1578 {
1579 const QString name = it->left( equalIdx ).toUpper();
1580 int metaEnumVal = metaEnum.keyToValue( name.toStdString().c_str() );
1581 if ( metaEnumVal < 0 )
1582 {
1583 continue; //option for a different format
1584 }
1585 const T option = ( T ) metaEnumVal;
1586 const QString value = it->right( it->length() - equalIdx - 1 );
1587 options.insert( option, value );
1588 }
1589 }
1590 return options;
1591 }
1592
1593 private:
1594 static bool isExternalLayer( const QString &name );
1595
1596 bool loadParameter( const QString &name, const QString &value ) override;
1597
1598 void save( const QgsWmsParameter &parameter, bool multi = false );
1599
1600 QgsWmsParameter idParameter( QgsWmsParameter::Name name, int id ) const;
1601
1602 void raiseError( const QString &msg ) const;
1603 void log( const QString &msg, const char *file = __builtin_FILE(), const char *function = __builtin_FUNCTION(), int line = __builtin_LINE() ) const;
1604
1605 QgsWmsParametersExternalLayer externalLayerParameter( const QString &name ) const;
1606
1607 QMultiMap<QString, QgsWmsParametersFilter> layerFilters( const QStringList &layers ) const;
1608
1609
1610 QMultiMap<QgsWmsParameter::Name, QgsWmsParameter> mWmsParameters;
1611 QMap<QString, QMap<QString, QString>> mExternalWMSParameters;
1612 QList<QgsProjectVersion> mVersions;
1613 };
1614} // namespace QgsWms
1615
1616#endif
TextRenderFormat
Options for rendering text.
Definition qgis.h:2991
FeatureSymbologyExport
Options for exporting features considering their symbology.
Definition qgis.h:6180
A geometry is the spatial representation of a feature.
Stores the appearance and layout settings for legend drawing with QgsLegendRenderer.
FilterVersion
OGC filter version.
Describes the version of a project.
A rectangle specified with double values.
QgsServerParameterDefinition(const QMetaType::Type type=QMetaType::Type::QString, const QVariant defaultValue=QVariant(""))
Constructor for QgsServerParameterDefinition.
Provides an interface to retrieve and manipulate global parameters received from the client.
QString value(const QString &key) const
Returns the value of a parameter.
WMS parameter received from the client.
int toInt() const
Converts the parameter into an integer.
QList< QgsGeometry > toGeomList(const char delimiter=',', bool skipEmptyParts=true) const
Converts the parameter into a list of geometries.
double toDouble() const
Converts the parameter into a double.
void raiseError() const
Raises an error in case of an invalid conversion.
QgsWmsParameter(const QgsWmsParameter::Name name=QgsWmsParameter::UNKNOWN, const QMetaType::Type type=QMetaType::Type::QString, const QVariant defaultValue=QVariant(""))
Constructor for QgsWmsParameter.
QList< double > toDoubleList(const char delimiter=',', bool skipEmptyParts=true) const
Converts the parameter into a list of doubles.
QStringList toStyleList(const char delimiter=',', bool skipEmptyParts=false) const
Converts the parameter into a list of strings and keeps empty parts Default style value is an empty s...
~QgsWmsParameter() override=default
Default destructor for QgsWmsParameter.
Name
Available parameters for WMS requests.
QUrl toUrl() const
Converts the parameter into an url.
bool isValid() const override
Returns true if the parameter is valid, false otherwise.
QString name() const
Returns the name of the parameter.
QgsRectangle toRectangle() const
Converts the parameter into a rectangle.
QList< int > toIntList(const char delimiter=',', bool skipEmptyParts=true) const
Converts the parameter into a list of integers.
QColor toColor() const
Converts the parameter into a color.
QgsWmsParameter::Name mName
QList< QColor > toColorList(const char delimiter=',', bool skipEmptyParts=true) const
Converts the parameter into a list of colors.
int mMapId
Map id for prefixed parameters (e.g. "0" for "map0:LAYERS" in GetPrint requests).
QString loadUrl() const
Loads the data associated to the parameter converted into an url.
bool htmlInfoOnlyMapTip() const
Returns true if only maptip information is requested for HTML feature info response.
QString rule() const
Returns RULE parameter or an empty string if none is defined.
QString layerTitle() const
Returns LAYERTITLE parameter or an empty string if not defined.
double layerSpaceAsDouble() const
Returns LAYERSPACE as a double or its default value if not defined.
QString boxSpace() const
Returns BOXSPACE parameter or an empty string if not defined.
QString wmsPrecision() const
Returns WMS_PRECISION parameter or an empty string if not defined.
double dxfScale() const
Returns the DXF SCALE parameter.
QString featureCount() const
Returns FEATURE_COUNT parameter or an empty string if none is defined.
QFont layerFont() const
Returns the layer font (built thanks to the LAYERFONTFAMILY, LAYERFONTSIZE, LAYERFONTBOLD,...
QList< int > opacitiesAsInt() const
Returns the list of opacities found in OPACITIES parameter as integers.
bool transparentAsBool() const
Returns TRANSPARENT parameter as a bool or its default value if not defined.
QString transparent() const
Returns TRANSPARENT parameter or an empty string if not defined.
~QgsWmsParameters() override=default
QList< int > highlightLabelWeightAsInt() const
Returns HIGHLIGHT_LABELWEIGHT as a list of int.
QString iconLabelSpace() const
Returns ICONLABELSPACE parameter or an empty string if not defined.
QString layerTitleSpace() const
Returns LAYERTITLESPACE parameter or an empty string if not defined.
QString x() const
Returns X parameter or an empty string if not defined.
QgsWmsParameters(const QgsServerParameters &parameters)
Constructor for WMS parameters with specific values.
QString layerSpace() const
Returns LAYERSPACE parameter or an empty string if not defined.
int wmsPrecisionAsInt() const
Returns WMS_PRECISION parameter as an int or its default value if not defined.
QStringList highlightLabelBufferSize() const
Returns HIGHLIGHT_LABELBUFFERSIZE.
QStringList allLayersNickname() const
Returns nickname of layers found in LAYER and LAYERS parameters.
QString formatAsString() const
Returns FORMAT parameter as a string.
double layerFontSizeAsDouble() const
Returns LAYERFONTSIZE as a double.
QString externalWMSUri(const QString &id) const
Returns the external WMS uri.
QList< double > highlightLabelFrameSizeAsFloat() const
Returns HIGHLIGHT_LABELFRAMESIZE as a list of float.
QgsProjectVersion versionAsNumber() const
Returns VERSION parameter if defined or its default value.
QString scale() const
Returns SCALE parameter or an empty string if none is defined.
QString ruleLabel() const
Returns RULELABEL parameter or an empty string if none is defined.
double scaleAsDouble() const
Returns SCALE as a double.
bool layerFontItalicAsBool() const
Returns LAYERFONTITALIC as a boolean or its default value if not defined.
QgsWmsParametersComposerMap composerMapParameters(int mapId) const
Returns the requested parameters for a composer map parameter.
QgsRectangle bboxAsRectangle() const
Returns BBOX as a rectangle if defined and valid.
bool withGeometry() const
Returns if the client wants the feature info response with geometry information.
QList< QColor > highlightLabelFrameBackgroundColorAsColor() const
Returns HIGHLIGHT_LABELFRAMEBACKGROUNDCOLOR as a list of colors.
QStringList highlightLabelString() const
Returns HIGHLIGHT_LABELSTRING as a list of string.
QString tiled() const
Returns TILED parameter or an empty string if not defined.
QString layerFontSize() const
Returns LAYERFONTSIZE parameter or an empty string if not defined.
DxfFormatOption
Options for DXF format.
QList< QColor > highlightLabelColorAsColor() const
Returns HIGHLIGHT_LABELCOLOR as a list of color.
bool itemFontBoldAsBool() const
Returns ITEMFONTBOLD as a boolean or its default value if not defined.
QStringList highlightLabelHorizontalAlignment() const
Returns HIGHLIGHT_LABEL_HORIZONTAL_ALIGNMENT as a list of string.
void set(QgsWmsParameter::Name name, const QVariant &value)
Sets a parameter value thanks to its name.
QString pointTolerance() const
Returns FI_POINT_TOLERANCE parameter or an empty string if not defined.
QStringList highlightLabelFrameSize() const
Returns HIGHLIGHT_LABELFRAMESIZE.
QString filterGeom() const
Returns the filter geometry found in FILTER_GEOM parameter.
QString composerTemplate() const
Returns TEMPLATE parameter or an empty string if not defined.
Format infoFormat() const
Returns infoFormat.
QString dxfCodec() const
Returns the DXF CODEC parameter.
QString y() const
Returns Y parameter or an empty string if not defined.
QString srcHeight() const
Returns SRCHEIGHT parameter or an empty string if not defined.
double dpiAsDouble() const
Returns DPI parameter as an int or its default value if not defined.
QStringList highlightLabelVerticalAlignment() const
Returns HIGHLIGHT_LABEL_VERTICAL_ALIGNMENT as a list of string.
void dump() const
Dumps parameters.
int pointToleranceAsInt() const
Returns FI_POINT_TOLERANCE parameter as an integer.
bool withMapTip() const
withMapTip
QString polygonTolerance() const
Returns FI_POLYGON_TOLERANCE parameter or an empty string if not defined.
QStringList highlightGeom() const
Returns HIGHLIGHT_GEOM as a list of string in WKT.
QString i() const
Returns I parameter or an empty string if not defined.
bool pdfLosslessImageCompression() const
Returns true if images embedded in pdf must be compressed using a lossless algorithm.
QList< QColor > highlightLabelBufferColorAsColor() const
Returns HIGHLIGHT_LABELBUFFERCOLOR as a list of colors.
QString request() const override
Returns REQUEST parameter as a string or an empty string if not defined.
double layerTitleSpaceAsDouble() const
Returns LAYERTITLESPACE as a double.
QList< QgsWmsParametersLayer > layersParameters() const
Returns parameters for each layer found in LAYER/LAYERS.
int lineToleranceAsInt() const
Returns FI_LINE_TOLERANCE parameter as an integer.
QList< double > highlightLabelBufferSizeAsFloat() const
Returns HIGHLIGHT_LABELBUFFERSIZE as a list of float.
QString lineTolerance() const
Returns FI_LINE_TOLERANCE parameter or an empty string if not defined.
bool showFeatureCountAsBool() const
Returns SHOWFEATURECOUNT as a bool.
QStringList pdfExportMapThemes() const
Returns map themes for geospatial PDF export.
Q_DECL_DEPRECATED bool pdfUseOgcBestPracticeFormatGeoreferencing() const
Returns true if OGC best practice georeferencing shall be used.
QStringList highlightLabelColor() const
Returns HIGHLIGHT_LABELCOLOR as a list of string.
bool pdfExportMetadata() const
Returns true if metadata shall be added to the pdf.
bool versionIsValid(const QString version) const
Returns true if version is valid, false otherwise.
QString j() const
Returns J parameter or an empty string if not defined.
int xAsInt() const
Returns X parameter as an int or its default value if not defined.
QColor layerFontColorAsColor() const
Returns LAYERFONTCOLOR as a color or its defined value if not defined.
QString bbox() const
Returns BBOX if defined or an empty string.
QgsWmsParameters()
Constructor for WMS parameters with default values only.
int heightAsInt() const
Returns HEIGHT parameter as an int or its default value if not defined.
QStringList highlightLabelWeight() const
Returns HIGHLIGHT_LABELWEIGHT as a list of string.
QString backgroundColor() const
Returns BGCOLOR parameter or an empty string if not defined.
QStringList allStyles() const
Returns styles found in STYLE and STYLES parameters.
double symbolWidthAsDouble() const
Returns SYMBOLWIDTH as a double or its default value if not defined.
QColor backgroundColorAsColor() const
Returns BGCOLOR parameter as a QColor or its default value if not defined.
Format format() const
Returns format.
QgsWmsParameter operator[](QgsWmsParameter::Name name) const
Returns the parameter corresponding to name.
QString itemFontSize() const
Returns ITEMFONTSIZE parameter or an empty string if not defined.
QStringList atlasPk() const
Returns the ATLAS_PK parameter.
QList< QgsGeometry > highlightGeomAsGeom() const
Returns HIGHLIGHT_GEOM as a list of geometries.
QString layerFontFamily() const
Returns LAYERFONTFAMILY parameter or an empty string if not defined.
QString withMapTipAsString() const
withMapTipAsString
QList< QgsWmsParametersHighlightLayer > highlightLayersParameters() const
Returns parameters for each highlight layer.
int iAsInt() const
Returns I parameter as an int or its default value if not defined.
QList< QColor > highlightLabelFrameOutlineColorAsColor() const
Returns HIGHLIGHT_LABELFRAMEOUTLINECOLOR as a list of colors.
QStringList highlightLabelBufferColor() const
Returns HIGHLIGHT_LABELBUFFERCOLOR as a list of string.
QStringList highlightLabelFrameOutlineWidth() const
Returns HIGHLIGHT_LABELFRAMEOUTLINEWIDTH.
bool pdfAppendGeoreference() const
Returns true if georeference info shall be added to the pdf.
int polygonToleranceAsInt() const
Returns FI_POLYGON_TOLERANCE parameter as an integer.
bool ruleLabelAsBool() const
Returns RULELABEL as a bool.
QList< double > highlightLabelDistance() const
Returns HIGHLIGHT_LABEL_DISTANCE as a list of double.
QList< int > highlightLabelSizeAsInt() const
Returns HIGHLIGHT_LABELSIZE as a list of int An exception is raised if an invalid size is found.
int widthAsInt() const
Returns WIDTH parameter as an int or its default value if not defined.
QString sldBody() const
Returns SLD_body if defined or an empty string.
bool itemFontItalicAsBool() const
Returns ITEMFONTITALIC as a boolean or its default value if not defined.
bool pdfDisableTiledRasterRendering() const
Returns true if rasters shall be untiled in the pdf.
QColor itemFontColorAsColor() const
Returns ITEMFONTCOLOR as a color.
double itemFontSizeAsDouble() const
Returns ITEMFONTSIZE as a double.
QString layerFontColor() const
Returns LAYERFONTCOLOR parameter or an empty string if not defined.
QString layoutParameter(const QString &id, bool &ok) const
Returns a layout parameter thanks to its id.
bool dxfUseLayerTitleAsName() const
Returns the DXF USE_TITLE_AS_LAYERNAME parameter.
QString symbolHeight() const
Returns SYMBOLHEIGHT parameter or an empty string if not defined.
int imageQualityAsInt() const
Returns IMAGE_QUALITY parameter as an integer.
bool pdfForceVectorOutput() const
Returns if pdf should be exported as vector.
QStringList highlightLabelFrameOutlineColor() const
Returns HIGHLIGHT_LABELFRAMEOUTLINECOLOR.
bool writeGeospatialPdf() const
Returns if a geospatial PDF shall be exported.
bool pdfUseIso32000ExtensionFormatGeoreferencing() const
Returns true, if Iso32000 georeferencing shall be used.
QMap< QString, QString > dimensionValues() const
Returns the dimensions parameter.
QList< QgsWmsParametersExternalLayer > externalLayersParameters() const
Returns parameters for each external layer.
bool withDisplayName() const
withDisplayName
int infoFormatVersion() const
Returns the infoFormat version for GML.
QStringList highlightLabelFrameBackgroundColor() const
Returns HIGHLIGHT_LABELFRAMEBACKGROUNDCOLOR.
QString layerFontBold() const
Returns LAYERFONTBOLD parameter or an empty string if not defined.
QgsLegendSettings legendSettings() const
Returns legend settings.
int srcHeightAsInt() const
Returns SRCHEIGHT parameter as an int or its default value if not defined.
QString symbolSpace() const
Returns SYMBOLSPACE parameter or an empty string if not defined.
QString itemFontBold() const
Returns ITEMFONTBOLD parameter or an empty string if not defined.
double symbolSpaceAsDouble() const
Returns SYMBOLSPACE as a double or its default value if not defined.
QString infoFormatAsString() const
Returns INFO_FORMAT parameter as a string.
QStringList highlightLabelFont() const
Returns HIGHLIGHT_LABELFONT.
Qgis::TextRenderFormat pdfTextRenderFormat() const
Returns text render format for pdf export.
QString wmtver() const
Returns WMTVER parameter or an empty string if not defined.
QStringList dxfLayerAttributes() const
Returns the DXF LAYERATTRIBUTES parameter.
QString srcWidth() const
Returns SRCWIDTH parameter or an empty string if not defined.
Qgis::FeatureSymbologyExport dxfMode() const
Returns the DXF MODE parameter.
QStringList highlightLabelSize() const
Returns HIGHLIGHT_LABELSIZE as a list of string.
QString imageQuality() const
Returns IMAGE_QUALITY parameter or an empty string if not defined.
QList< double > highlightLabelRotation() const
Returns HIGHLIGHT_LABEL_ROTATION as a list of double.
QString height() const
Returns HEIGHT parameter or an empty string if not defined.
QString crs() const
Returns CRS or an empty string if none is defined.
bool showRuleDetailsAsBool() const
Returns SHOWRULEDETAILS as a bool.
QStringList selections() const
Returns the list of feature selection found in SELECTION parameter.
int featureCountAsInt() const
Returns FEATURE_COUNT as an integer.
int yAsInt() const
Returns Y parameter as an int or its default value if not defined.
bool layerTitleAsBool() const
Returns LAYERTITLE as a bool or its default value if not defined.
QMap< T, QString > formatOptions() const
Returns the format options for an output format.
QString itemFontColor() const
Returns ITEMFONTCOLOR parameter or an empty string if not defined.
double boxSpaceAsDouble() const
Returns BOXSPACE as a double or its default value if not defined.
bool addLayerGroups() const
Returns true if layer groups shall be added to GetLegendGraphic results.
QString symbolWidth() const
Returns SYMBOLWIDTH parameter or an empty string if not defined.
bool tiledAsBool() const
Returns TILED parameter as a boolean.
QList< double > highlightLabelFrameOutlineWidthAsFloat() const
Returns HIGHLIGHT_LABELFRAMEOUTLINEWIDTH as a list of widths.
Format
Output format for the response.
QString width() const
Returns WIDTH parameter or an empty string if not defined.
QFont itemFont() const
Returns the item font (built thanks to the ITEMFONTFAMILY, ITEMFONTSIZE, ITEMFONTBOLD,...
QStringList opacities() const
Returns the list of opacities found in OPACITIES parameter.
QString version() const override
Returns VERSION parameter as a string or an empty string if not defined.
QString layerFontItalic() const
Returns LAYERFONTITALIC parameter or an empty string if not defined.
QString itemFontItalic() const
Returns ITEMFONTITALIC parameter or an empty string if not defined.
QStringList filters() const
Returns the list of filters found in FILTER parameter.
QString dpi() const
Returns DPI parameter or an empty string if not defined.
QString itemFontFamily() const
Returns ITEMFONTFAMILY parameter or an empty string if not defined.
int jAsInt() const
Returns J parameter as an int or its default value if not defined.
QVector< qreal > pdfPredefinedMapScales() const
Returns list of map scales.
QString showFeatureCount() const
Returns SHOWFEATURECOUNT parameter or an empty string if none is defined.
bool pdfSimplifyGeometries() const
Returns if geometries shall to be simplified.
bool layerFontBoldAsBool() const
Returns LAYERFONTBOLD as a boolean or its default value if not defined.
double iconLabelSpaceAsDouble() const
Returns ICONLABELSPACE as a double or its default value if not defined.
QStringList highlightSymbol() const
Returns HIGHLIGHT_SYMBOL as a list of string.
QStringList queryLayersNickname() const
Returns nickname of layers found in QUERY_LAYERS parameter.
double symbolHeightAsDouble() const
Returns SYMBOLHEIGHT as a double or its default value if not defined.
bool infoFormatIsImage() const
Checks if INFO_FORMAT parameter is one of the image formats (PNG, JPG).
int srcWidthAsInt() const
Returns SRCWIDTH parameter as an int or its default value if not defined.
Median cut implementation.
QList< QgsWmsParametersLayer > mLayers
QList< QgsWmsParametersHighlightLayer > mHighlightLayers
QgsWmsParametersFilter::Type mType
QgsOgcUtils::FilterVersion mVersion
QList< QgsWmsParametersFilter > mFilter