Skip to content

Import Export

Tobia edited this page May 21, 2013 · 4 revisions

Import-Export Plugin

The MapComposer component provide a GUI tool that allows the user to import/export data (currently supported import / export of map and kml / kmz files). To enable these tools you have to build and deploy the servicebox service in your servlet container.

ServiceBox is basically a backend support that provide import/export functionalities through 'ad hoc' Java Servlets. You can find all necessary information about how to build and deploy ServiceBox here.

When you have build and deployed the ServiceBox backend component, you can enable the ImportExport plugin simply adding the proper configuration below inside the mapStoreConfig.js file (default) or your own configuration file used. As an instance:

 {
     "ptype": "gxp_importexport",
     "service": "http://localhost:8080/servicebox/",
     "types": ["map","kml/kmz"],
     "actionTarget": "paneltbar",
     "index": 28
 }

The "types" array property defines the data types that you want to manage (supported ['map', 'kml/kmz']). You have to add the plugin configration above in 'customTools' for example as you can see in mapStoreConfig.js file.

You can directly download the lates servicebox here. Before the deploy you have to rename the WAR file in servicebox.war.