Changeset 36 for trunk/zoo-services/ogr
- Timestamp:
- Oct 2, 2010, 1:16:14 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/zoo-services/ogr/base-vect-ops/service.c
r35 r36 23 23 */ 24 24 25 #include <libintl.h>26 #include <locale.h>27 #define _(String) dgettext ("zoo-services",String)28 29 25 #include "cpl_conv.h" 30 26 #include "ogr_api.h" … … 32 28 #include "geos_c.h" 33 29 #include "service.h" 34 30 #include "service_internal.h" 35 31 36 32 extern "C" { … … 91 87 free(tmp); 92 88 if(res==NULL){ 93 setMapInMaps(conf,"lenv","message",_ ("Unable to call OGR_G_CreatFromGML"));89 setMapInMaps(conf,"lenv","message",_ss("Unable to call OGR_G_CreatFromGML")); 94 90 return NULL; 95 91 } … … 111 107 map* tmp=getMapFromMaps(inputs,"InputPolygon","value"); 112 108 if(!tmp){ 113 setMapInMaps(conf,"lenv","message",_ ("Unable to parse the input geometry from InputPolygon"));109 setMapInMaps(conf,"lenv","message",_ss("Unable to parse the input geometry from InputPolygon")); 114 110 return SERVICE_FAILED; 115 111 } … … 123 119 } 124 120 else{ 125 setMapInMaps(conf,"lenv","message",_ ("Unable to find any geometry for InputPolygon"));121 setMapInMaps(conf,"lenv","message",_ss("Unable to find any geometry for InputPolygon")); 126 122 return SERVICE_FAILED; 127 123 } 128 124 if(geometry==NULL){ 129 setMapInMaps(conf,"lenv","message",_ ("Unable to parse the input geometry from InputPolygon"));125 setMapInMaps(conf,"lenv","message",_ss("Unable to parse the input geometry from InputPolygon")); 130 126 return SERVICE_FAILED; 131 127 } … … 179 175 map* tmp=getMapFromMaps(inputs,"InputPolygon","value"); 180 176 if(!tmp){ 181 setMapInMaps(conf,"lenv","message",_ ("Unable to parse the input geometry from InputPolygon"));177 setMapInMaps(conf,"lenv","message",_ss("Unable to parse the input geometry from InputPolygon")); 182 178 return SERVICE_FAILED; 183 179 } … … 199 195 geometry=createGeometryFromGML(conf,tmp->value); 200 196 if(geometry==NULL){ 201 setMapInMaps(conf,"lenv","message",_ ("Unable to parse the input geometry from InputPolygon"));197 setMapInMaps(conf,"lenv","message",_ss("Unable to parse the input geometry from InputPolygon")); 202 198 return SERVICE_FAILED; 203 199 } … … 256 252 map* tmp=getMapFromMaps(inputs,"InputPolygon","value"); 257 253 if(tmp==NULL){ 258 setMapInMaps(conf,"lenv","message",_ ("Unable to fetch input geometry"));254 setMapInMaps(conf,"lenv","message",_ss("Unable to fetch input geometry")); 259 255 return SERVICE_FAILED; 260 256 }else 261 257 if(strlen(tmp->value)<=0){ 262 setMapInMaps(conf,"lenv","message",_ ("Unable to fetch input geometry"));258 setMapInMaps(conf,"lenv","message",_ss("Unable to fetch input geometry")); 263 259 return SERVICE_FAILED; 264 260 } … … 269 265 geometry=createGeometryFromGML(conf,tmp->value); 270 266 if(geometry==NULL){ 271 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry"));267 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry")); 272 268 return SERVICE_FAILED; 273 269 } … … 360 356 } 361 357 if(geometry1==NULL){ 362 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry for InputEntity1."));358 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry for InputEntity1.")); 363 359 fprintf(stderr,"SERVICE FAILED !\n"); 364 360 return SERVICE_FAILED; … … 390 386 fprintf(stderr,"\nService internal print1 InputEntity2 Final\n"); 391 387 if(geometry2==NULL){ 392 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry for InputEntity2."));388 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry for InputEntity2.")); 393 389 fprintf(stderr,"SERVICE FAILED !\n"); 394 390 return SERVICE_FAILED; … … 466 462 } 467 463 if(geometry1==NULL){ 468 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry for InputEntity1."));464 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry for InputEntity1.")); 469 465 fprintf(stderr,"SERVICE FAILED !\n"); 470 466 return SERVICE_FAILED; … … 489 485 } 490 486 if(geometry2==NULL){ 491 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry for InputEntity2."));487 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry for InputEntity2.")); 492 488 fprintf(stderr,"SERVICE FAILED !\n"); 493 489 return SERVICE_FAILED; … … 517 513 map* tmp=getMapFromMaps(inputs,"InputPolygon","value"); 518 514 if(tmp==NULL){ 519 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry from InputPolygon"));515 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry from InputPolygon")); 520 516 return SERVICE_FAILED; 521 517 } … … 523 519 geometry=createGeometryFromGML(conf,tmp->value); 524 520 if(geometry==NULL){ 525 setMapInMaps(conf,"lenv","message",_ ("Unable to parse input geometry from InputPolygon"));521 setMapInMaps(conf,"lenv","message",_ss("Unable to parse input geometry from InputPolygon")); 526 522 return SERVICE_FAILED; 527 523 }
Note: See TracChangeset
for help on using the changeset viewer.