QGIS API Documentation 3.99.0-Master (2fe06baccd8)
Loading...
Searching...
No Matches
qgsmaplayerserverpropertieswidget.h
Go to the documentation of this file.
1/***************************************************************************
2 qgsmaplayerserverpropertieswidget.h
3 ---------------------
4 begin : 2025/02/20
5 copyright : (C) 2025 by Julien Cabieces
6 email : julien dot cabieces at oslandia dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16#ifndef QGSMAPLAYERSERVERPROPERTIESWIDGET
17#define QGSMAPLAYERSERVERPROPERTIESWIDGET
18
19#include "ui_qgsmaplayerserverpropertieswidgetbase.h"
20
21#include "qgis_gui.h"
22
23#define SIP_NO_FILE
24
26class QStandardItemModel;
27
36class GUI_EXPORT QgsMapLayerServerPropertiesWidget : public QWidget, private Ui::QgsMapLayerServerPropertiesWidgetBase
37{
38 Q_OBJECT
39
40 public:
45 QgsMapLayerServerPropertiesWidget( QWidget *parent = nullptr );
46
50 void setServerProperties( QgsMapLayerServerProperties *serverProperties );
51
57 void setHasWfsTitle( bool hasWfsTitle );
58
63 bool hasWfsTitle() const;
64
70 bool save();
71
75 void sync();
76
77 private slots:
78
79 void addMetadataUrl();
80 void removeSelectedMetadataUrl();
81
82 private:
83 QgsMapLayerServerProperties *mServerProperties = nullptr;
84 QStandardItemModel *mMetadataUrlModel = nullptr;
85 bool mHasWfsTitle = true;
86};
87
88
89#endif
void setHasWfsTitle(bool hasWfsTitle)
Set whether or not server properties widget has to display a WFS title widget.
QgsMapLayerServerPropertiesWidget(QWidget *parent=nullptr)
Constructor.
bool hasWfsTitle() const
Returns true if widget display a WFS title widget.
void setServerProperties(QgsMapLayerServerProperties *serverProperties)
Sets the server properties serverProperties associated with the widget.
bool save()
Saves the settings to the server properties.
void sync()
Updates the widget state to match the current server properties state.
Manages QGIS Server properties for a map layer.