This library can be used as a python library. The following examples intended to demonstrate the library usage.
This example shows how to extract bounding box from a single file
import geoextent.lib.extent as geoextent
geoextent.fromFile('tests/testdata/geojson/muenster_ring_zeit.geojson', True, False)
{'format': 'application/geojson', 'crs': 4326, 'bbox': [7.60168075561523, 51.9488147720619, 7.64725685119629, 51.9746240298775]}
This example shows how to extract time interval from a single file
import geoextent.lib.extent as geoextent
geoextent.fromFile('tests/testdata/geojson/muenster_ring_zeit.geojson', False, True)
{'format': 'application/geojson', 'tbox': ['2018-11-14', '2018-11-14']}
This example shows how to extract both bounding box and time interval from a single file
import geoextent.lib.extent as geoextent
geoextent.fromFile('tests/testdata/geojson/muenster_ring_zeit.geojson', True, True)
{'format': 'application/geojson', 'tbox': ['2018-11-14', '2018-11-14'], 'crs': 4326, 'bbox': [7.60168075561523, 51.9488147720619, 7.64725685119629, 51.9746240298775]}