pymviewer 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pymviewer-0.1.0.dist-info/METADATA +68 -0
- pymviewer-0.1.0.dist-info/RECORD +23 -0
- pymviewer-0.1.0.dist-info/WHEEL +5 -0
- pymviewer-0.1.0.dist-info/entry_points.txt +2 -0
- pymviewer-0.1.0.dist-info/licenses/LICENSE +674 -0
- pymviewer-0.1.0.dist-info/top_level.txt +1 -0
- qgisxmviewer/__init__.py +21 -0
- qgisxmviewer/cli.py +67 -0
- qgisxmviewer/converters/__init__.py +1 -0
- qgisxmviewer/converters/geojson.py +26 -0
- qgisxmviewer/converters/wfs.py +36 -0
- qgisxmviewer/converters/wms.py +43 -0
- qgisxmviewer/exceptions.py +9 -0
- qgisxmviewer/models.py +52 -0
- qgisxmviewer/qgis_project.py +260 -0
- qgisxmviewer/services/__init__.py +1 -0
- qgisxmviewer/services/qgis_to_mviewer.py +86 -0
- qgisxmviewer/utils.py +162 -0
- qgisxmviewer/wms_capabilities.py +191 -0
- qgisxmviewer/writer/__init__.py +1 -0
- qgisxmviewer/writer/complete_xml.py +81 -0
- qgisxmviewer/writer/create_xml.py +68 -0
- qgisxmviewer/writer/mviewer_xml.py +48 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pymviewer
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Generate mviewer XML configurations from QGIS Server projects and WMS capabilities.
|
|
5
|
+
Author: PSC mviewer
|
|
6
|
+
Author-email: Gaetan Bruel <gaetan.bruel@jdev.fr>
|
|
7
|
+
License-Expression: GPL-3.0-or-later
|
|
8
|
+
Project-URL: Homepage, https://github.com/jdev-org/pymviewer
|
|
9
|
+
Project-URL: Repository, https://github.com/jdev-org/pymviewer
|
|
10
|
+
Project-URL: Issues, https://github.com/jdev-org/pymviewer/issues
|
|
11
|
+
Classifier: Programming Language :: Python :: 3
|
|
12
|
+
Classifier: Programming Language :: Python :: 3 :: Only
|
|
13
|
+
Classifier: Operating System :: OS Independent
|
|
14
|
+
Requires-Python: >=3.10
|
|
15
|
+
Description-Content-Type: text/markdown
|
|
16
|
+
License-File: LICENSE
|
|
17
|
+
Dynamic: license-file
|
|
18
|
+
|
|
19
|
+
# pymviewer
|
|
20
|
+
|
|
21
|
+
`pymviewer` generates mviewer XML configuration files from QGIS Server
|
|
22
|
+
projects and WMS GetCapabilities documents.
|
|
23
|
+
|
|
24
|
+
## Install
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
python -m pip install -e qgisxmviewer
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## CLI
|
|
31
|
+
|
|
32
|
+
Generate from a QGIS project:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
pymviewer from-qgs \
|
|
36
|
+
--project /path/to/project.qgs \
|
|
37
|
+
--output /path/to/config.xml \
|
|
38
|
+
--service-url http://localhost:90/ogc/data
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Generate from a WMS GetCapabilities file:
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
pymviewer from-capabilities \
|
|
45
|
+
--capabilities /path/to/GetCapabilities.xml \
|
|
46
|
+
--output /path/to/config.xml \
|
|
47
|
+
--service-url http://localhost:90/ogc/data
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## Python API
|
|
51
|
+
|
|
52
|
+
```python
|
|
53
|
+
from pathlib import Path
|
|
54
|
+
from pymviewer.qgisxmviewer import create_mviewer_config_from_wms_capabilities
|
|
55
|
+
|
|
56
|
+
create_mviewer_config_from_wms_capabilities(
|
|
57
|
+
Path("data_getcapabilities.xml"),
|
|
58
|
+
Path("data.xml"),
|
|
59
|
+
"http://localhost:90/ogc/data",
|
|
60
|
+
)
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Notes
|
|
64
|
+
|
|
65
|
+
- mviewer layer `id` values are normalized and unique.
|
|
66
|
+
- WMS layer names are preserved in the `layers` attribute.
|
|
67
|
+
- WMS legend URLs are encoded and can be rebased to an override service URL.
|
|
68
|
+
- `.qgs` projects are supported. `.qgz` archives are not supported yet.
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
pymviewer-0.1.0.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
2
|
+
qgisxmviewer/__init__.py,sha256=xHmdUU7Cl3tcQ4ihqbh6-D8j_yoRMhy7JyMu-Ncr56k,703
|
|
3
|
+
qgisxmviewer/cli.py,sha256=rvzWZ4dBZj4jcKUF5d134jwWur5l1ShdV-QcK0Hr2hU,2279
|
|
4
|
+
qgisxmviewer/exceptions.py,sha256=i316EQ5j0KXKSNfAF0xWPvMDLOXHHFNcP13BhmQLVRo,284
|
|
5
|
+
qgisxmviewer/models.py,sha256=OycrtE3fUKh7ckUqyKWjR7ijjmIUsbX3Nb7JVZu4cdc,1243
|
|
6
|
+
qgisxmviewer/qgis_project.py,sha256=0cg2W5NWIwk6NIpI6A8j3iG_BoouKJca5fPCHHs3HKk,9647
|
|
7
|
+
qgisxmviewer/utils.py,sha256=1snObqi6cUO-OqxQs8DG5x0mpLB5F7ZMysujktrKTc8,5623
|
|
8
|
+
qgisxmviewer/wms_capabilities.py,sha256=Pm34iGT3FBOuLX4eA_qM6zZ5XNZvhDclfVm8JuVJG_s,6896
|
|
9
|
+
qgisxmviewer/converters/__init__.py,sha256=CdQjMO8nl23Dgb04wO7SWZDdfbdE_mVg1ttAZUqZpFo,38
|
|
10
|
+
qgisxmviewer/converters/geojson.py,sha256=BMTvnGS0AeUr9-Bv9bA1fXve-2zY7stSxkbToJN4ZEQ,870
|
|
11
|
+
qgisxmviewer/converters/wfs.py,sha256=rPUOn4sGjv9vd_x_j-IhBFQHryuhlOhV9LPYRKvGn5U,1145
|
|
12
|
+
qgisxmviewer/converters/wms.py,sha256=CQy6nZLaNQQoOXBhy8CdfNpT3C5zqK0d-EocYOLneZ8,1619
|
|
13
|
+
qgisxmviewer/services/__init__.py,sha256=FhCB5umrfV-R6mtGfIc3MHuBQTL2ZzP66sP2fb9iRxU,45
|
|
14
|
+
qgisxmviewer/services/qgis_to_mviewer.py,sha256=LEkWlW3306L7f3ay1wj529QgttXS4OZoNvpROqTvHzs,3293
|
|
15
|
+
qgisxmviewer/writer/__init__.py,sha256=k2TWpHxF0tqnnVW--MaGN9fZaDIfF350hnK3-eKnJ98,34
|
|
16
|
+
qgisxmviewer/writer/complete_xml.py,sha256=q93MVuW3yImnn0Y2AfMgsZwWoR-TlopnhfrOvYLXP1U,2796
|
|
17
|
+
qgisxmviewer/writer/create_xml.py,sha256=arafTWlh4m9KLalD-J0hFRuccP6qnhmgT_p7naJznug,2275
|
|
18
|
+
qgisxmviewer/writer/mviewer_xml.py,sha256=lGUdQS1ZYZaGH15Yw1HaUo2YWdjL0ge1Iqwqts7kQro,1459
|
|
19
|
+
pymviewer-0.1.0.dist-info/METADATA,sha256=EgRN__WS9wI1-Cr35Ad8P9bv5c3uWrhJ1FcwvD7yVLM,1844
|
|
20
|
+
pymviewer-0.1.0.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
|
|
21
|
+
pymviewer-0.1.0.dist-info/entry_points.txt,sha256=0Hc4YbiR5TN6b_lRBDZcCClfK-Q4nfC6h9FQgbU2bak,52
|
|
22
|
+
pymviewer-0.1.0.dist-info/top_level.txt,sha256=fjcgOtQL3XtIQfKmQN0-54tu7vXDH_OIbz33cOmDGRY,13
|
|
23
|
+
pymviewer-0.1.0.dist-info/RECORD,,
|