Maps-add-on import/export Shapefile

Hi All

Did somebody already write some code to import / export ShapeFiles from the maps-add-on ?

Regards

Felix

Hi, Felix!

Jmix Maps add‑on does not provide an API for Shapefile import/export. However, implementing import/export is not as difficult as it seems. The Maps add‑on already uses JTS geometry types, so you can convert them to and from Shapefiles.

You should use the GeoTools library. Do not forget to add the repository:

repositories {
    maven { url 'https://repo.osgeo.org/repository/release/' }
}

See code examples for export: Feature Tutorial — GeoTools 36.x User Guide
And for import: Shapefile Plugin — GeoTools 36.x User Guide

1 Like