wfs20


Namewfs20 JSON
Version 0.2.2 PyPI version JSON
download
home_page
SummarySmall library to request geospatial data (WFS)
upload_time2023-03-12 15:44:54
maintainer
docs_urlNone
author
requires_python>=3.7
licenseBSD
keywords wfs gis request vector
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # wfs20: Small library for requesting geospatial data (WFS)

## What is it?
wfs20 is a small library with the sole purpose of making it easy
on the user to request geospatial data from a WebFeatureService.
wfs20 only caters to the 2.0.0 version of the WebFeatureService 
for now. wfs20 will be expanded in the future to also contain the
1.0.0 and 1.1.0 version of the WebFeatureService.

## Where to get it?
Source code is available at this repository on Github:
https://github.com/B-Dalmijn/WFS20

The package can be installed from:

```sh
# PyPI
pip install wfs20
```

## What can it do?
Some of its functionality is listed below:

  - Get the capabilities and metadata of/from the service

  ```sh
  # service
  from wfs20 import WebFeatureService
  wfs = WebFeatureService(url)

  # metadata
  wfs.Constraints 
  wfs.FeatureTypes 
  wfs.FeatureTypeMeta 
  wfs.GetCapabilitiesMeta
  wfs.GetFeatureMeta
  wfs.Keywords
  ```

  - Request geospatial data from the service

  ```sh
  reader = wfs.RequestData("<layer>",(x1,y1,x2,y2),proj_code)
  # proj_code is the projection code corresponding with the geospatial data
  # to be requested and the given bbox (x1,y1,x2,y2)
  ```

    The returned reader object holds the geospatial data and 
    subsequent metadata

  - Export the requested data to the harddrive, as long as there is 
    data in the reader object

  ```sh
  # to gml
  wfs.ToFile("<folder>",format="gml")
  ```

  ```sh
  # to ESRI ShapeFile
  wfs.ToFile("<folder>",format="shp")
  ```

  - It is completely modular, so if you know the capabilities of the service,
    you don't really need to use the WebFeatureService class

    E.g.

  ```sh
  from wfs20.crs import CRS
  from wfs20.reader import DataReader
  from wfs20.request import CreateGetRequest

  crs = CRS.from_epsg(epsg)

  url = CreateGetRequest(
    service_url,
    version,
    featuretype,
    bbox,
    crs
    )

  reader = DataReader(url,keyword)
  ```
    keyword is in general the Title of the featuretype, e.g. 'bag:pand' -> keyword is 'pand'
    Where again you have a reader object holding the geospatial data

  - Both GET and POST requests are supported, though wfs20.RequestData only supports GET request
    url and POST request data can however be implemented in the DataReader

  ```sh
  from wfs20.request import CreatePostRequest

  url,data = CreatePostRequest(
    url,
    version,
    featuretype,
    bbox,
    crs
    )

  reader = DataReader(url,keyword,method="POST",data=data)
  ```

  Again one would have a reader object holding the acquired geospatial data.

## Dependencies
  - [requests:    HTTP library]
  - [lxml:        XML parsing library]

## Additional packages
These packages improve the functionality wfs20 package
  - [GDAL:        Geospatial Data Abstraction Library]

GDAL can either be installed from the conda repository via:

```sh
conda install gdal
```

Or from a wheel (.whl) file. Wheel files for GDAL are very kindly made by
Christoph Gohlke and are in the releases of this [repository on github](https://github.com/cgohlke/geospatial.whl/).
The newest GDAL wheel file of Gohlke will always be in the newest release of wfs20 on github.

Simply install the wheel file with pip:

```sh
# GDAL 3.6.2 for python 3.10
pip install GDAL-3.6.2-cp310-cp310-win_amd64.whl
```

## License
[BSD 3](https://github.com/B-Dalmijn/WFS20/blob/master/LICENSE)

## Questions/ suggestions/ requests/ bugs?
Send an email to brencodeert@outlook.com

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "wfs20",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "\"B.W. Dalmijn\" <brencodeert@outlook.com>",
    "keywords": "wfs,GIS,request,vector",
    "author": "",
    "author_email": "\"B.W. Dalmijn\" <brencodeert@outlook.com>",
    "download_url": "https://files.pythonhosted.org/packages/8d/bd/d710ff4d0a3d521340ca9718173c1c36bb293101a32a9d4e5ebcd42681e7/wfs20-0.2.2.tar.gz",
    "platform": null,
    "description": "# wfs20: Small library for requesting geospatial data (WFS)\r\n\r\n## What is it?\r\nwfs20 is a small library with the sole purpose of making it easy\r\non the user to request geospatial data from a WebFeatureService.\r\nwfs20 only caters to the 2.0.0 version of the WebFeatureService \r\nfor now. wfs20 will be expanded in the future to also contain the\r\n1.0.0 and 1.1.0 version of the WebFeatureService.\r\n\r\n## Where to get it?\r\nSource code is available at this repository on Github:\r\nhttps://github.com/B-Dalmijn/WFS20\r\n\r\nThe package can be installed from:\r\n\r\n```sh\r\n# PyPI\r\npip install wfs20\r\n```\r\n\r\n## What can it do?\r\nSome of its functionality is listed below:\r\n\r\n  - Get the capabilities and metadata of/from the service\r\n\r\n  ```sh\r\n  # service\r\n  from wfs20 import WebFeatureService\r\n  wfs = WebFeatureService(url)\r\n\r\n  # metadata\r\n  wfs.Constraints \r\n  wfs.FeatureTypes \r\n  wfs.FeatureTypeMeta \r\n  wfs.GetCapabilitiesMeta\r\n  wfs.GetFeatureMeta\r\n  wfs.Keywords\r\n  ```\r\n\r\n  - Request geospatial data from the service\r\n\r\n  ```sh\r\n  reader = wfs.RequestData(\"<layer>\",(x1,y1,x2,y2),proj_code)\r\n  # proj_code is the projection code corresponding with the geospatial data\r\n  # to be requested and the given bbox (x1,y1,x2,y2)\r\n  ```\r\n\r\n    The returned reader object holds the geospatial data and \r\n    subsequent metadata\r\n\r\n  - Export the requested data to the harddrive, as long as there is \r\n    data in the reader object\r\n\r\n  ```sh\r\n  # to gml\r\n  wfs.ToFile(\"<folder>\",format=\"gml\")\r\n  ```\r\n\r\n  ```sh\r\n  # to ESRI ShapeFile\r\n  wfs.ToFile(\"<folder>\",format=\"shp\")\r\n  ```\r\n\r\n  - It is completely modular, so if you know the capabilities of the service,\r\n    you don't really need to use the WebFeatureService class\r\n\r\n    E.g.\r\n\r\n  ```sh\r\n  from wfs20.crs import CRS\r\n  from wfs20.reader import DataReader\r\n  from wfs20.request import CreateGetRequest\r\n\r\n  crs = CRS.from_epsg(epsg)\r\n\r\n  url = CreateGetRequest(\r\n    service_url,\r\n    version,\r\n    featuretype,\r\n    bbox,\r\n    crs\r\n    )\r\n\r\n  reader = DataReader(url,keyword)\r\n  ```\r\n    keyword is in general the Title of the featuretype, e.g. 'bag:pand' -> keyword is 'pand'\r\n    Where again you have a reader object holding the geospatial data\r\n\r\n  - Both GET and POST requests are supported, though wfs20.RequestData only supports GET request\r\n    url and POST request data can however be implemented in the DataReader\r\n\r\n  ```sh\r\n  from wfs20.request import CreatePostRequest\r\n\r\n  url,data = CreatePostRequest(\r\n    url,\r\n    version,\r\n    featuretype,\r\n    bbox,\r\n    crs\r\n    )\r\n\r\n  reader = DataReader(url,keyword,method=\"POST\",data=data)\r\n  ```\r\n\r\n  Again one would have a reader object holding the acquired geospatial data.\r\n\r\n## Dependencies\r\n  - [requests:    HTTP library]\r\n  - [lxml:        XML parsing library]\r\n\r\n## Additional packages\r\nThese packages improve the functionality wfs20 package\r\n  - [GDAL:        Geospatial Data Abstraction Library]\r\n\r\nGDAL can either be installed from the conda repository via:\r\n\r\n```sh\r\nconda install gdal\r\n```\r\n\r\nOr from a wheel (.whl) file. Wheel files for GDAL are very kindly made by\r\nChristoph Gohlke and are in the releases of this [repository on github](https://github.com/cgohlke/geospatial.whl/).\r\nThe newest GDAL wheel file of Gohlke will always be in the newest release of wfs20 on github.\r\n\r\nSimply install the wheel file with pip:\r\n\r\n```sh\r\n# GDAL 3.6.2 for python 3.10\r\npip install GDAL-3.6.2-cp310-cp310-win_amd64.whl\r\n```\r\n\r\n## License\r\n[BSD 3](https://github.com/B-Dalmijn/WFS20/blob/master/LICENSE)\r\n\r\n## Questions/ suggestions/ requests/ bugs?\r\nSend an email to brencodeert@outlook.com\r\n",
    "bugtrack_url": null,
    "license": "BSD",
    "summary": "Small library to request geospatial data (WFS)",
    "version": "0.2.2",
    "split_keywords": [
        "wfs",
        "gis",
        "request",
        "vector"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a0aabd48173f96e43ea9815499c6af2f6ab14818f28ab1c8a6ae27238a7f83c1",
                "md5": "a7670f07f740522a875652536180f415",
                "sha256": "3163fc751ddc590bc6339d3481c88ee0fa8b835f09db08144210af22773ee874"
            },
            "downloads": -1,
            "filename": "wfs20-0.2.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a7670f07f740522a875652536180f415",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 61528,
            "upload_time": "2023-03-12T15:44:52",
            "upload_time_iso_8601": "2023-03-12T15:44:52.230158Z",
            "url": "https://files.pythonhosted.org/packages/a0/aa/bd48173f96e43ea9815499c6af2f6ab14818f28ab1c8a6ae27238a7f83c1/wfs20-0.2.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "8dbdd710ff4d0a3d521340ca9718173c1c36bb293101a32a9d4e5ebcd42681e7",
                "md5": "2d475085a9f3ed5d26d8de5318e2f36c",
                "sha256": "0ca24da3a18bf8f62ea75a2a13c7fa19a717cf6c7952029841f75c7274ad5f32"
            },
            "downloads": -1,
            "filename": "wfs20-0.2.2.tar.gz",
            "has_sig": false,
            "md5_digest": "2d475085a9f3ed5d26d8de5318e2f36c",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 53832,
            "upload_time": "2023-03-12T15:44:54",
            "upload_time_iso_8601": "2023-03-12T15:44:54.313600Z",
            "url": "https://files.pythonhosted.org/packages/8d/bd/d710ff4d0a3d521340ca9718173c1c36bb293101a32a9d4e5ebcd42681e7/wfs20-0.2.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-03-12 15:44:54",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "wfs20"
}
        
Elapsed time: 0.04629s