ZooWorkshop/FOSS4GJapan/Exercice

Version 3 (modified by djay, 9 years ago)

--

Exercise

You know everything now about writting zcfg matadata files and get short pieces of code in service.c or ogr_service_provider.py depending if you choosen C or Python programming language respectively.

The goal of this exercise is to implement the following multiple geometries services :

  • Intersection
  • Union
  • Difference
  • SymDifference

C version

Your are now invited to edit the source.c file you have created during this workshop to add the multiple geometries, using the following OGR C-API functions :

You can use the Boundary.zcfg file as example, rename the InputPolygon input to InputEntity1 and add a similar input named IntputEntity2. You are invited to update other values in the ZOO Metadata File to set the proper metadata informations.

Python Version

Your are invited to edit the ogr_ws_service_provider.py file you created during this workshop to add the multiple geometries using the following osgeo.ogr Geometry methods applied on the first Geometry instance :

You can once again use the Boundary.zcfg file as example, rename the InputPolygon? input to InputEntity1 and add a similar input named IntputEntity2. You are invited to update other values in the ZOO metadata file to set the proper metadata informations.

Testing your services

Once the multiple geometries Services are deployed on your local environment, please reload the zoo-ogr.html created during the previous section from your browser and test your brand new ZOO Services.

Search

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png