Changes between Version 34 and Version 35 of ZooWorkshop/FOSS4GJapan/CreatingOGRBasedWebServices
- Timestamp:
- Oct 16, 2010, 12:57:26 AM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ZooWorkshop/FOSS4GJapan/CreatingOGRBasedWebServices
v34 v35 295 295 }}} 296 296 297 The only thing we will focus on is the call to the errorException function used in the function body. This function is declared in the {{{zoo-kernel/service_internal.h}}} and defined in {{{zoo- 297 The only thing we will focus on is the call to the errorException function used in the function body. This function is declared in the {{{zoo-kernel/service_internal.h}}} and defined in {{{zoo-kernel/service_internal.c}}} file. It takes three parameters as follow : 298 298 299 299 * the main environment {{{maps}}}, … … 378 378 }}} 379 379 380 The Boundary ZOO Service is now implemented and you need to compile it to produce a Shared Library. As you just used functions defined in service.h ({{{getMapFromMaps}}} and {{{addToMap}}}), you must include this file in your C code. The same requirement is needed to be able to use the errorException function declared in {{{zoo-kernel/service_internal.h}}}, you also must link your service object file to the {{{zoo- 380 The Boundary ZOO Service is now implemented and you need to compile it to produce a Shared Library. As you just used functions defined in service.h ({{{getMapFromMaps}}} and {{{addToMap}}}), you must include this file in your C code. The same requirement is needed to be able to use the errorException function declared in {{{zoo-kernel/service_internal.h}}}, you also must link your service object file to the {{{zoo-kernel/service_internal.o}}} in order to use {{{errorException}}} on runtime. You must then include the required files to access the libxml2 and OGR C-API. 381 381 382 382 For the need of the Shared Library, you have to put your code in a block declared as {{{extern "C"}}}. The final Service code should be stored in a service.c file located in the root of the Services Provider directory (so in {{{/home/zoows/sources/zoo-services/ws_sp}}}). It should look like this :