1 /* 2 rl2wms.h -- RasterLite2 common WMS support 3 4 version 2.0, 2013 July 28 5 6 Author: Sandro Furieri a.furieri@lqt.it 7 8 ------------------------------------------------------------------------------ 9 10 Version: MPL 1.1/GPL 2.0/LGPL 2.1 11 12 The contents of this file are subject to the Mozilla Public License Version 13 1.1 (the "License"); you may not use this file except in compliance with 14 the License. You may obtain a copy of the License at 15 http://www.mozilla.org/MPL/ 16 17 Software distributed under the License is distributed on an "AS IS" basis, 18 WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License 19 for the specific language governing rights and limitations under the 20 License. 21 22 The Original Code is the RasterLite2 library 23 24 The Initial Developer of the Original Code is Alessandro Furieri 25 26 Portions created by the Initial Developer are Copyright (C) 2013 27 the Initial Developer. All Rights Reserved. 28 29 Contributor(s): 30 31 32 Alternatively, the contents of this file may be used under the terms of 33 either the GNU General Public License Version 2 or later (the "GPL"), or 34 the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), 35 in which case the provisions of the GPL or the LGPL are applicable instead 36 of those above. If you wish to allow use of your version of this file only 37 under the terms of either the GPL or the LGPL, and not to allow others to 38 use your version of this file under the terms of the MPL, indicate your 39 decision by deleting the provisions above and replace them with the notice 40 and other provisions required by the GPL or the LGPL. If you do not delete 41 the provisions above, a recipient may use your version of this file under 42 the terms of any one of the MPL, the GPL or the LGPL. 43 44 */ 45 46 /** 47 \file rl2wms.h 48 49 WMS support 50 */ 51 52 #ifndef _RL2WMS_H 53 #ifndef DOXYGEN_SHOULD_SKIP_THIS 54 #define _RL2WMS_H 55 #endif 56 57 #ifdef __cplusplus 58 extern "C" 59 { 60 #endif 61 62 typedef struct rl2_wms_catalog rl2WmsCatalog; 63 typedef rl2WmsCatalog *rl2WmsCatalogPtr; 64 65 typedef struct rl2_wms_item rl2WmsLayer; 66 typedef rl2WmsLayer *rl2WmsLayerPtr; 67 68 typedef struct rl2_wms_tiled_item rl2WmsTiledLayer; 69 typedef rl2WmsTiledLayer *rl2WmsTiledLayerPtr; 70 71 typedef struct rl2_wms_tile_pattern rl2WmsTilePattern; 72 typedef rl2WmsTilePattern *rl2WmsTilePatternPtr; 73 74 typedef struct rl2_wms_feature_collection rl2WmsFeatureCollection; 75 typedef rl2WmsFeatureCollection *rl2WmsFeatureCollectionPtr; 76 77 typedef struct rl2_wms_feature_member rl2WmsFeatureMember; 78 typedef rl2WmsFeatureMember *rl2WmsFeatureMemberPtr; 79 80 typedef struct rl2_wms_cache rl2WmsCache; 81 typedef struct rl2_wms_cache *rl2WmsCachePtr; 82 83 /** 84 Creates a Catalog for some WMS service 85 86 \param cache_handle handle to local WMS cache 87 \param url pointer to some WMS-GetCapabilities XML Document. 88 \param proxy pointer to some HTTP PROXY: may be NULL. 89 \param err_msg on completion will contain an error message (if any) 90 91 \return the pointer to the corresponding WMS-Catalog object: NULL on failure 92 93 \sa destroy_wms_catalog, get_wms_version, get_wms_name, get_wms_title, get_wms_abstract, 94 is_wms_tile_service, get_wms_catalog_count, get_wms_catalog_layer 95 96 \note an eventual error message returned via err_msg requires to be deallocated 97 by invoking free().\n 98 you are responsible to destroy (before or after) any WMS-Catalog returned by create_wms_catalog(). 99 */ 100 RL2_DECLARE rl2WmsCatalogPtr create_wms_catalog (rl2WmsCachePtr 101 cache_handle, 102 const char *url, 103 const char *proxy, 104 char **err_msg); 105 106 /** 107 Destroys a WMS-Catalog object freeing any allocated resource 108 109 \param handle the pointer to a valid WMS-Catalog returned by a previous call 110 to create_wms_catalog() 111 112 \sa create_wms_catalog 113 */ 114 RL2_DECLARE void destroy_wms_catalog (rl2WmsCatalogPtr handle); 115 116 /** 117 Tests if a WMS-Catalog object actually corresponds to a TileService 118 119 \param handle the pointer to a valid WMS-Catalog returned by a previous call 120 to create_wms_catalog() 121 122 \return 0 (false) if not, any other value if yes: a negative value on error. 123 124 \sa create_wms_catalog, get_wms_tile_service_name, get_wms_tile_service_title, 125 get_wms_tile_service_abstract, get_wms_tile_service_count, get_wms_catalog_tiled_layer 126 */ 127 RL2_DECLARE int is_wms_tile_service (rl2WmsCatalogPtr handle); 128 129 /** 130 Return the TileService name corresponding to some WMS-Catalog object 131 132 \param handle the pointer to a valid WMS-Catalog (of the TileService type) 133 returned by a previous call to get_wms_catalog_layer(). 134 135 \return the name corresponding to the WMS TileService (if any) 136 137 \sa get_wms_tile_service_title, get_wms_tile_service_abstract 138 */ 139 RL2_DECLARE const char *get_wms_tile_service_name (rl2WmsCatalogPtr handle); 140 141 /** 142 Return the TileService title corresponding to some WMS-Catalog object 143 144 \param handle the pointer to a valid WMS-Catalog (of the TileService type) 145 returned by a previous call to get_wms_catalog_layer(). 146 147 \return the title corresponding to the WMS TileService (if any) 148 149 \sa get_wms_tile_service_name, get_wms_tile_service_abstract 150 */ 151 RL2_DECLARE const char *get_wms_tile_service_title (rl2WmsCatalogPtr 152 handle); 153 154 /** 155 Return the TileService abstract corresponding to some WMS-Catalog object 156 157 \param handle the pointer to a valid WMS-Catalog (of the TileService type) 158 returned by a previous call to get_wms_catalog_layer(). 159 160 \return the abstract corresponding to the WMS TileService (if any) 161 162 \sa get_wms_tile_service_title, get_wms_tile_service_title 163 */ 164 RL2_DECLARE const char *get_wms_tile_service_abstract (rl2WmsCatalogPtr 165 handle); 166 167 /** 168 Return the total count of first-level Layers defined within a WMS-Catalog object 169 170 \param handle the pointer to a valid WMS-Catalog returned by a previous call 171 to create_wms_catalog() 172 173 \return the total count of first-level Layers defined within a WMS-Catalog object: 174 a negative number if the WMS-Catalog isn't valid 175 176 \sa create_wms_catalog, get_wms_catalog_layer, get_wms_format_count, 177 get_wms_tile_service_count 178 */ 179 RL2_DECLARE int get_wms_catalog_count (rl2WmsCatalogPtr handle); 180 181 /** 182 Return the total count of first-level Tiled Layers defined within a 183 WMS-Catalog [TileService] object 184 185 \param handle the pointer to a valid WMS-Catalog returned by a previous call 186 to create_wms_catalog() 187 188 \return the total count of first-level Tiled Layers defined within a WMS-Catalog 189 [TileService] object: 190 a negative number if the WMS-Catalog isn't valid 191 192 \sa create_wms_catalog, get_wms_catalog_tiled, layer, get_wms_format_count, 193 get_wms_catalog_count 194 */ 195 RL2_DECLARE int get_wms_tile_service_count (rl2WmsCatalogPtr handle); 196 197 /** 198 Return the total count of Formats supported by a WMS-Catalog object 199 200 \param handle the pointer to a valid WMS-Catalog returned by a previous call 201 to create_wms_catalog() 202 \param mode TRUE if only valid "image formats" should be considered; 203 if set to FALSE then any possible format will be considered. 204 205 \return the total count of Formats supported by a WMS-Catalog object: 206 ZERO or a a negative number if the WMS-Catalog isn't valid 207 208 \sa create_wms_catalog, get_wms_format, get_wms_catalog_count 209 */ 210 RL2_DECLARE int get_wms_format_count (rl2WmsCatalogPtr handle, int mode); 211 212 /** 213 Return the version string corresponding to some WMS-Catalog object 214 215 \param handle the pointer to a valid WMS-Catalog returned by a previous call 216 to get_wms_catalog_layer(). 217 218 \return the version string corresponding to the WMS-Catalog object 219 220 \sa get_wms_name, get_wms_title, get_wms_abstract 221 */ 222 RL2_DECLARE const char *get_wms_version (rl2WmsCatalogPtr handle); 223 224 /** 225 Return the name corresponding to some WMS-Catalog object 226 227 \param handle the pointer to a valid WMS-Catalog returned by a previous call 228 to get_wms_catalog_layer(). 229 230 \return the name corresponding to the WMS-Catalog object 231 232 \sa get_wms_version, get_wms_title, get_wms_abstract 233 */ 234 RL2_DECLARE const char *get_wms_name (rl2WmsCatalogPtr handle); 235 236 /** 237 Return the title corresponding to some WMS-Catalog object 238 239 \param handle the pointer to a valid WMS-Catalog returned by a previous call 240 to get_wms_catalog_layer(). 241 242 \return the title corresponding to the WMS-Catalog object 243 244 \sa get_wms_version, get_wms_name, get_wms_abstract 245 */ 246 RL2_DECLARE const char *get_wms_title (rl2WmsCatalogPtr handle); 247 248 /** 249 Return the abstract corresponding to some WMS-Catalog object 250 251 \param handle the pointer to a valid WMS-Catalog returned by a previous call 252 to get_wms_catalog_layer(). 253 254 \return the abstract corresponding to the WMS-Catalog object 255 256 \sa get_wms_version, get_wms_name, get_wms_title 257 */ 258 RL2_DECLARE const char *get_wms_abstract (rl2WmsCatalogPtr handle); 259 260 /** 261 Return the GetMap URL (method GET) from a WMS-Catalog object 262 263 \param handle the pointer to a valid WMS-Catalog returned by a previous call 264 to create_wms_catalog() 265 266 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 267 268 \sa create_wms_catalog, get_wms_url_GetMap_post, get_wms_url_GetTileService_get, 269 get_wms_url_GetTileService_post, get_wms_url_GetFeatureInfo_get, 270 get_wms_url_GetFeatureInfo_post 271 */ 272 RL2_DECLARE const char *get_wms_url_GetMap_get (rl2WmsCatalogPtr handle); 273 274 /** 275 Return the GetMap URL (method POST) from a WMS-Catalog object 276 277 \param handle the pointer to a valid WMS-Catalog returned by a previous call 278 to create_wms_catalog() 279 280 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 281 282 \sa create_wms_catalog, get_wms_url_GetMap_get, get_wms_url_GetTileService_get, 283 get_wms_url_GetTileService_post, get_wms_url_GetFeatureInfo_get, 284 get_wms_url_GetFeatureInfo_post 285 */ 286 RL2_DECLARE const char *get_wms_url_GetMap_post (rl2WmsCatalogPtr handle); 287 288 /** 289 Return the GetTileService URL (method GET) from a WMS-Catalog object 290 291 \param handle the pointer to a valid WMS-Catalog returned by a previous call 292 to create_wms_catalog() 293 294 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 295 296 \sa create_wms_catalog, get_wms_url_GetMap_get, get_wms_url_GetMap_post, 297 get_wms_url_GetTileService_post, get_wms_url_GetFeatureInfo_get, 298 get_wms_url_GetFeatureInfo_post 299 */ 300 RL2_DECLARE const char *get_wms_url_GetTileService_get (rl2WmsCatalogPtr 301 handle); 302 303 /** 304 Return the GetTileService URL (method POST) from a WMS-Catalog object 305 306 \param handle the pointer to a valid WMS-Catalog returned by a previous call 307 to create_wms_catalog() 308 309 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 310 311 \sa create_wms_catalog, get_wms_url_GetMap_get, get_wms_url_GetMap_post, 312 get_wms_url_GetTileService_get, get_wms_url_GetFeatureInfo_get, 313 get_wms_url_GetFeatureInfo_post 314 */ 315 RL2_DECLARE const char *get_wms_url_GetTileService_post (rl2WmsCatalogPtr 316 handle); 317 318 /** 319 Return the GetFeatureInfo URL (method GET) from a WMS-Catalog object 320 321 \param handle the pointer to a valid WMS-Catalog returned by a previous call 322 to create_wms_catalog() 323 324 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 325 326 \sa create_wms_catalog, get_wms_url_GetMap_get, get_wms_url_GetMap_post, 327 get_wms_url_GetTileService_get, get_wms_url_GetTileService_post, 328 get_wms_url_GetFeatureInfo_post, get_wms_gml_mime_type, get_wms_xml_mime_type 329 */ 330 RL2_DECLARE const char *get_wms_url_GetFeatureInfo_get (rl2WmsCatalogPtr 331 handle); 332 333 /** 334 Return the GetFeatureInfo URL (method POST) from a WMS-Catalog object 335 336 \param handle the pointer to a valid WMS-Catalog returned by a previous call 337 to create_wms_catalog() 338 339 \return the corresponding URL: NULL if the URL is not defined or if any error is encountered. 340 341 \sa create_wms_catalog, get_wms_url_GetMap_get, get_wms_url_GetMap_post, 342 get_wms_url_GetTileService_get, get_wms_url_GetTileService_post, 343 get_wms_url_GetFeatureInfo_get, get_wms_gml_mime_type, get_wms_xml_mime_type 344 */ 345 RL2_DECLARE const char *get_wms_url_GetFeatureInfo_post (rl2WmsCatalogPtr 346 handle); 347 348 /** 349 Return the GML MIME type name from a WMS-Catalog object 350 351 \param handle the pointer to a valid WMS-Catalog returned by a previous call 352 to create_wms_catalog() 353 354 \return the MIME type corresponding to GML: NULL if it's not defined or if any error is encountered. 355 356 \sa create_wms_catalog, get_wms_url_GetFeatureInfo_get, get_wms_url_GetFeatureInfo_post, 357 get_wms_xml_mime_type 358 */ 359 RL2_DECLARE const char *get_wms_gml_mime_type (rl2WmsCatalogPtr handle); 360 361 /** 362 Return the XML MIME type name from a WMS-Catalog object 363 364 \param handle the pointer to a valid WMS-Catalog returned by a previous call 365 to create_wms_catalog() 366 367 \return the MIME type corresponding to XML: NULL if it's not defined or if any error is encountered. 368 369 \sa create_wms_catalog, get_wms_url_GetFeatureInfo_get, get_wms_url_GetFeatureInfo_post, 370 get_wms_gml_mime_type 371 */ 372 RL2_DECLARE const char *get_wms_xml_mime_type (rl2WmsCatalogPtr handle); 373 374 /** 375 Return the Contact Person defined by a WMS-Catalog object 376 377 \param handle the pointer to a valid WMS-Catalog returned by a previous call 378 to create_wms_catalog() 379 380 \return the Contact Person: NULL if undeclared/unspecified. 381 382 \sa create_wms_catalog, get_wms_format_count 383 */ 384 RL2_DECLARE const char *get_wms_contact_person (rl2WmsCatalogPtr handle); 385 386 /** 387 Return the Contact Organization defined by a WMS-Catalog object 388 389 \param handle the pointer to a valid WMS-Catalog returned by a previous call 390 to create_wms_catalog() 391 392 \return the Contact Organization: NULL if undeclared/unspecified. 393 394 \sa create_wms_catalog, get_wms_format_count 395 */ 396 RL2_DECLARE const char *get_wms_contact_organization (rl2WmsCatalogPtr 397 handle); 398 399 /** 400 Return the Contact Position defined by a WMS-Catalog object 401 402 \param handle the pointer to a valid WMS-Catalog returned by a previous call 403 to create_wms_catalog() 404 405 \return the Contact Position: NULL if undeclared/unspecified. 406 407 \sa create_wms_catalog, get_wms_format_count 408 */ 409 RL2_DECLARE const char *get_wms_contact_position (rl2WmsCatalogPtr handle); 410 411 /** 412 Return the Postal Address defined by a WMS-Catalog object 413 414 \param handle the pointer to a valid WMS-Catalog returned by a previous call 415 to create_wms_catalog() 416 417 \return the Postal Address: NULL if undeclared/unspecified. 418 419 \sa create_wms_catalog, get_wms_format_count 420 */ 421 RL2_DECLARE const char *get_wms_contact_postal_address (rl2WmsCatalogPtr 422 handle); 423 424 /** 425 Return the City (Postal Address) defined by a WMS-Catalog object 426 427 \param handle the pointer to a valid WMS-Catalog returned by a previous call 428 to create_wms_catalog() 429 430 \return the City (Postal Address): NULL if undeclared/unspecified. 431 432 \sa create_wms_catalog, get_wms_format_count 433 */ 434 RL2_DECLARE const char *get_wms_contact_city (rl2WmsCatalogPtr handle); 435 436 /** 437 Return the State or Provicne (Postal Address) defined by a WMS-Catalog object 438 439 \param handle the pointer to a valid WMS-Catalog returned by a previous call 440 to create_wms_catalog() 441 442 \return the State or Province (Postal Address): NULL if undeclared/unspecified. 443 444 \sa create_wms_catalog, get_wms_format_count 445 */ 446 RL2_DECLARE const char *get_wms_contact_state_province (rl2WmsCatalogPtr 447 handle); 448 449 /** 450 Return the Post Code (Postal Address) defined by a WMS-Catalog object 451 452 \param handle the pointer to a valid WMS-Catalog returned by a previous call 453 to create_wms_catalog() 454 455 \return the Post Code (Postal Address) : NULL if undeclared/unspecified. 456 457 \sa create_wms_catalog, get_wms_format_count 458 */ 459 RL2_DECLARE const char *get_wms_contact_post_code (rl2WmsCatalogPtr handle); 460 461 /** 462 Return the Country (Postal Address) defined by a WMS-Catalog object 463 464 \param handle the pointer to a valid WMS-Catalog returned by a previous call 465 to create_wms_catalog() 466 467 \return the Country (Postal Address): NULL if undeclared/unspecified. 468 469 \sa create_wms_catalog, get_wms_format_count 470 */ 471 RL2_DECLARE const char *get_wms_contact_country (rl2WmsCatalogPtr handle); 472 473 /** 474 Return the Voice Telephone defined by a WMS-Catalog object 475 476 \param handle the pointer to a valid WMS-Catalog returned by a previous call 477 to create_wms_catalog() 478 479 \return the Voice Telephone: NULL if undeclared/unspecified. 480 481 \sa create_wms_catalog, get_wms_format_count 482 */ 483 RL2_DECLARE const char *get_wms_contact_voice_telephone (rl2WmsCatalogPtr 484 handle); 485 486 /** 487 Return the FAX Telephone defined by a WMS-Catalog object 488 489 \param handle the pointer to a valid WMS-Catalog returned by a previous call 490 to create_wms_catalog() 491 492 \return the FAX Telephone: NULL if undeclared/unspecified. 493 494 \sa create_wms_catalog, get_wms_format_count 495 */ 496 RL2_DECLARE const char *get_wms_contact_fax_telephone (rl2WmsCatalogPtr 497 handle); 498 499 /** 500 Return the e-mail Address defined by a WMS-Catalog object 501 502 \param handle the pointer to a valid WMS-Catalog returned by a previous call 503 to create_wms_catalog() 504 505 \return the e-mail Address: NULL if undeclared/unspecified. 506 507 \sa create_wms_catalog, get_wms_format_count 508 */ 509 RL2_DECLARE const char *get_wms_contact_email_address (rl2WmsCatalogPtr 510 handle); 511 512 /** 513 Return the Fees required by a WMS-Catalog object 514 515 \param handle the pointer to a valid WMS-Catalog returned by a previous call 516 to create_wms_catalog() 517 518 \return the required Fees: NULL if undeclared/unspecified. 519 520 \sa create_wms_catalog, get_wms_format_count 521 */ 522 RL2_DECLARE const char *get_wms_fees (rl2WmsCatalogPtr handle); 523 524 /** 525 Return the Access Constraints supported by a WMS-Catalog object 526 527 \param handle the pointer to a valid WMS-Catalog returned by a previous call 528 to create_wms_catalog() 529 530 \return the imposed Access Constraints: NULL if undeclared/unspecified. 531 532 \sa create_wms_catalog, get_wms_format_count 533 */ 534 RL2_DECLARE const char *get_wms_access_constraints (rl2WmsCatalogPtr 535 handle); 536 537 /** 538 Return the Layer Limit supported by a WMS-Catalog object 539 540 \param handle the pointer to a valid WMS-Catalog returned by a previous call 541 to create_wms_catalog() 542 543 \return the supported Layer Limit: a negative number if undeclared/unspecified. 544 545 \sa create_wms_catalog, get_wms_format_count 546 */ 547 RL2_DECLARE int get_wms_layer_limit (rl2WmsCatalogPtr handle); 548 549 /** 550 Return the MaxWidth supported by a WMS-Catalog object 551 552 \param handle the pointer to a valid WMS-Catalog returned by a previous call 553 to create_wms_catalog() 554 555 \return the MaxWidth measured in pixels: a negative number if undeclared/unspecified. 556 557 \sa create_wms_catalog, get_wms_format_count 558 */ 559 RL2_DECLARE int get_wms_max_width (rl2WmsCatalogPtr handle); 560 561 /** 562 Return the MaxHeight supported by a WMS-Catalog object 563 564 \param handle the pointer to a valid WMS-Catalog returned by a previous call 565 to create_wms_catalog() 566 567 \return the MaxHeight measured in pixels: a negative number if undeclared/unspecified. 568 569 \sa create_wms_catalog, get_wms_format_count 570 */ 571 RL2_DECLARE int get_wms_max_height (rl2WmsCatalogPtr handle); 572 573 /** 574 Return one of the Formats supported by a WMS-Catalog object 575 576 \param handle the pointer to a valid WMS-Catalog returned by a previous call 577 to create_wms_catalog() 578 \param index the relative index identifying the required Format (the first 579 Format value supported by a WMS-Catalog object has index ZERO). 580 \param mode TRUE if only valid "image formats" should be considered; 581 if set to FALSE then any possible format will be considered. 582 583 \return the Format string: NULL if the required Format isn't defined. 584 585 \sa create_wms_catalog, get_wms_format_count 586 */ 587 RL2_DECLARE const char *get_wms_format (rl2WmsCatalogPtr handle, 588 int index, int mode); 589 590 /** 591 Return the pointer to some specific Layer defined within a WMS-Catalog object 592 593 \param handle the pointer to a valid WMS-Catalog returned by a previous call 594 to create_wms_catalog() 595 \param index the relative index identifying the required WMS-Layer (the first 596 Layer in the WMS-Catalaog object has index ZERO). 597 598 \return the pointer to the required WMS-Layer object: NULL if the passed index 599 isn't valid 600 601 \sa create_wms_catalog, get_wms_catalog_count, get_wms_layer_name, get_wms_layer_title, 602 get_wms_layer_abstract, get_wms_layer_crs_count, get_wms_layer_crs 603 */ 604 RL2_DECLARE rl2WmsLayerPtr get_wms_catalog_layer (rl2WmsCatalogPtr 605 handle, int index); 606 607 /** 608 Testing if some WMS-Layer object has Layer children 609 610 \param handle the pointer to a valid WMS-Layer returned by a previous call 611 to get_wms_catalog_layer(). 612 613 \return 0 (false) if not, any other value if yes 614 615 \sa get_wms_catalog_layer, get_wms_layer_children_count, get_wms_child_layer 616 */ 617 RL2_DECLARE int wms_layer_has_children (rl2WmsLayerPtr handle); 618 619 /** 620 Return the total count of children Layers defined within a WMS-Layer object 621 622 \param handle the pointer to a valid WMS-Layer 623 624 \return the total count of children Layers defined within a WMS-Layer object: 625 a negative number if the WMS-Layer isn't valid 626 627 \sa get_wms_catalog_layer, wms_layer_has_children, get_wms_child_layer 628 */ 629 RL2_DECLARE int get_wms_layer_children_count (rl2WmsLayerPtr handle); 630 631 /** 632 Return the pointer to some child Layer defined within a WMS-Layer object 633 634 \param handle the pointer to a valid WMS-Layer 635 \param index the relative index identifying the required WMS-Layer (the first 636 child Layer in the WMS-Layer object has index ZERO). 637 638 \return the pointer to the required WMS-Layer object: NULL if the passed index 639 isn't valid 640 641 \sa get_wms_catalog_layer, wms_layer_has_children, get_wms_layer_children_count 642 */ 643 RL2_DECLARE rl2WmsLayerPtr get_wms_child_layer (rl2WmsLayerPtr 644 handle, int index); 645 646 /** 647 Return the name corresponding to some WMS-Layer object 648 649 \param handle the pointer to a valid WMS-Layer returned by a previous call 650 to get_wms_catalog_layer(). 651 652 \return the name corresponding to the WMS-Layer object 653 654 \sa get_wms_layer_title, get_wms_layer_abstract, get_wms_layer_crs_count, get_wms_layer_crs, 655 wms_layer_has_children 656 */ 657 RL2_DECLARE const char *get_wms_layer_name (rl2WmsLayerPtr handle); 658 659 /** 660 Return the title corresponding to some WMS-Layer object 661 662 \param handle the pointer to a valid WMS-Layer returned by a previous call 663 to get_wms_catalog_layer(). 664 665 \return the title corresponding to the WMS-Layer object 666 667 \sa get_wms_layer_name, get_wms_layer_abstract, get_wms_layer_crs_count, get_wms_layer_crs 668 */ 669 RL2_DECLARE const char *get_wms_layer_title (rl2WmsLayerPtr handle); 670 671 /** 672 Return the abstract corresponding to some WMS-Layer object 673 674 \param handle the pointer to a valid WMS-Layer returned by a previous call 675 to get_wms_catalog_layer(). 676 677 \return the abstract corresponding to the WMS-Layer object 678 679 \sa get_wms_layer_name, get_wms_layer_title, get_wms_layer_crs_count, get_wms_layer_crs 680 */ 681 RL2_DECLARE const char *get_wms_layer_abstract (rl2WmsLayerPtr handle); 682 683 /** 684 Return the total count of CRSs supported by a WMS-Layer object 685 686 \param handle the pointer to a valid WMS-Layer returned by a previous call 687 to get_wms_catalog_layer(). 688 689 \return the total count of CRSs supported by a WMS-Layer object: 690 ZERO or a negative number if the WMS-Layer isn't valid 691 692 \sa get_wms_layer_name, get_wms_layer_title, get_wms_layer_abstract, 693 get_wms_layer_crs, get_wms_layer_style_count 694 */ 695 RL2_DECLARE int get_wms_layer_crs_count (rl2WmsLayerPtr handle); 696 697 /** 698 Return one of the CRSs supported by a WMS-Layer object 699 700 \param handle the pointer to a valid WMS-Layer returned by a previous call 701 to get_wms_catalog_layer(). 702 \param index the relative index identifying the required CRS (the first 703 CRS value supported by a WMS-Layer object has index ZERO). 704 705 \return the CRS string: NULL if the required CRS isn't defined. 706 707 \sa get_wms_layer_name, get_wms_layer_title, get_wms_layer_abstract, 708 get_wms_layer_crs_count 709 */ 710 RL2_DECLARE const char *get_wms_layer_crs (rl2WmsLayerPtr handle, 711 int index); 712 713 /** 714 Tests if some WMS-Layer object declares the Opaque property 715 716 \param handle the pointer to a valid WMS-Layer returned by a previous call 717 to get_wms_catalog_layer(). 718 719 \return TRUE or FALSE: a negative number if undefined/unspecified or if 720 isn't a valid WMS-Layer. 721 722 \sa get_wms_layer_name, get_wms_layer_title, get_wms_layer_abstract, 723 is_wms_layer_queriable 724 */ 725 RL2_DECLARE int is_wms_layer_opaque (rl2WmsLayerPtr handle); 726 727 /** 728 Tests if some WMS-Layer object declares the Queryable property 729 730 \param handle the pointer to a valid WMS-Layer returned by a previous call 731 to get_wms_catalog_layer(). 732 733 \return TRUE or FALSE: a negative number if undefined/unspecified or if 734 isn't a valid WMS-Layer. 735 736 \sa get_wms_layer_name, get_wms_layer_title, get_wms_layer_abstract, 737 is_wms_layer_transparent 738 */ 739 RL2_DECLARE int is_wms_layer_queryable (rl2WmsLayerPtr handle); 740 741 /** 742 Return the total count of Styles supported by a WMS-Layer object 743 744 \param handle the pointer to a valid WMS-Layer returned by a previous call 745 to get_wms_catalog_layer(). 746 747 \return the total count of Styles supported by a WMS-Layer object: 748 ZERO or a negative number if the WMS-Layer isn't valid 749 750 \sa get_wms_layer_crs_count, get_wms_layer_style_name, get_wms_layer_style_title, 751 get_wms_layer_style_abstract 752 */ 753 RL2_DECLARE int get_wms_layer_style_count (rl2WmsLayerPtr handle); 754 755 /** 756 Return the Min Scale Denominator supported by a WMS-Layer object 757 758 \param handle the pointer to a valid WMS-Layer returned by a previous call 759 to get_wms_catalog_layer(). 760 761 \return the Min Scale Denominator declared by a WMS-Layer object: 762 DBL_MAX if undeclared or if the WMS-Layer isn't valid 763 764 \sa get_wms_layer_crs_count, get_wms_layer_max_scale_denominator 765 */ 766 RL2_DECLARE double get_wms_layer_min_scale_denominator (rl2WmsLayerPtr 767 handle); 768 769 /** 770 Return the Max Scale Denominator supported by a WMS-Layer object 771 772 \param handle the pointer to a valid WMS-Layer returned by a previous call 773 to get_wms_catalog_layer(). 774 775 \return the Max Scale Denominator declared by a WMS-Layer object: 776 DBL_MAX if undeclared or if the WMS-Layer isn't valid 777 778 \sa get_wms_layer_crs_count, get_wms_layer_min_scale_denominator 779 */ 780 RL2_DECLARE double get_wms_layer_max_scale_denominator (rl2WmsLayerPtr 781 handle); 782 783 /** 784 Return the Geographic Bounding Box (long/lat) declared by a WMS-Layer object 785 786 \param handle the pointer to a valid WMS-Layer returned by a previous call 787 to get_wms_catalog_layer(). 788 \param minx on successful completion will contain the Min Longitude 789 \param maxx on successful completion will contain the Max Longitude 790 \param miny on successful completion will contain the Min Latitude 791 \param maxy on successful completion will contain the Max Latitude 792 793 \return TRUE on success, FALSE if any error occurred 794 795 \sa get_wms_layer_bbbox 796 */ 797 RL2_DECLARE int get_wms_layer_geo_bbox (rl2WmsLayerPtr handle, double *minx, 798 double *maxx, double *miny, 799 double *maxy); 800 801 /** 802 Return the Bounding Box corresponding to some CRS declared by a WMS-Layer object 803 804 \param handle the pointer to a valid WMS-Layer returned by a previous call 805 to get_wms_catalog_layer(). 806 \param crs the string value identifying some specific CRS 807 \param minx on successful completion will contain the Min Longitude 808 \param maxx on successful completion will contain the Max Longitude 809 \param miny on successful completion will contain the Min Latitude 810 \param maxy on successful completion will contain the Max Latitude 811 812 \return TRUE on success, FALSE if any error occurred 813 814 \sa get_wms_layer_geo_bbox 815 */ 816 RL2_DECLARE int get_wms_layer_bbox (rl2WmsLayerPtr handle, const char *crs, 817 double *minx, double *maxx, 818 double *miny, double *maxy); 819 820 /** 821 Return the Name of some Style supported by a WMS-Layer object 822 823 \param handle the pointer to a valid WMS-Layer returned by a previous call 824 to get_wms_catalog_layer(). 825 \param index the relative index identifying the required Style (the first 826 Style supported by a WMS-Layer object has index ZERO). 827 828 \return the Style's Name: NULL if the required Style isn't defined. 829 830 \sa get_wms_layer_style_count, get_wms_layer_style_title, get_wms_layer_style_abstract 831 */ 832 RL2_DECLARE const char *get_wms_layer_style_name (rl2WmsLayerPtr handle, 833 int index); 834 835 /** 836 Return the Title of some Style supported by a WMS-Layer object 837 838 \param handle the pointer to a valid WMS-Layer returned by a previous call 839 to get_wms_catalog_layer(). 840 \param index the relative index identifying the required Style (the first 841 Style supported by a WMS-Layer object has index ZERO). 842 843 \return the Style's Title: NULL if the required Style isn't defined. 844 845 \sa get_wms_layer_style_count, get_wms_layer_style_name, get_wms_layer_style_abstract 846 */ 847 RL2_DECLARE const char *get_wms_layer_style_title (rl2WmsLayerPtr handle, 848 int index); 849 850 /** 851 Return the Abstract of some Style supported by a WMS-Layer object 852 853 \param handle the pointer to a valid WMS-Layer returned by a previous call 854 to get_wms_catalog_layer(). 855 \param index the relative index identifying the required Style (the first 856 Style supported by a WMS-Layer object has index ZERO). 857 858 \return the Style's Abstract: NULL if the required Style isn't defined. 859 860 \sa get_wms_layer_style_count, get_wms_layer_style_name, get_wms_layer_style_title 861 */ 862 RL2_DECLARE const char *get_wms_layer_style_abstract (rl2WmsLayerPtr handle, 863 int index); 864 865 /** 866 Return the pointer to some specific Tiled Layer defined within a WMS-Catalog object 867 868 \param handle the pointer to a valid WMS-Catalog [of the TileService type] 869 returned by a previous call to create_wms_catalog() 870 \param index the relative index identifying the required WMS-TiledLayer (the first 871 Tiled Layer in the WMS-Catalaog object has index ZERO). 872 873 \return the pointer to the required WMS-TiledLayer object: NULL if the passed index 874 isn't valid 875 876 \sa create_wms_catalog, get_wms_tile_service_count, get_wms_tiled_layer_name, 877 get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, get_wms_tiled_layer_crs 878 */ 879 RL2_DECLARE rl2WmsTiledLayerPtr 880 get_wms_catalog_tiled_layer (rl2WmsCatalogPtr handle, int index); 881 882 /** 883 Testing if some WMS-TiledLayer object has TiledLayer children 884 885 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 886 to get_wms_catalog_tiled_layer(). 887 888 \return 0 (false) if not, any other value if yes 889 890 \sa get_wms_catalog_tiled_layer, get_wms_tiled_layer_children_count, get_wms_child_tiled_layer 891 */ 892 RL2_DECLARE int wms_tiled_layer_has_children (rl2WmsTiledLayerPtr handle); 893 894 /** 895 Return the total count of children TiledLayers defined within a WMS-TiledLayer object 896 897 \param handle the pointer to a valid WMS-TiledLayer 898 899 \return the total count of children TiledLayers defined within a WMS-TiledLayer object: 900 a negative number if the WMS-TiledLayer isn't valid 901 902 \sa get_wms_catalog_tiled_layer, wms_tiled_layer_has_children, get_wms_child_layer 903 */ 904 RL2_DECLARE int get_wms_tiled_layer_children_count (rl2WmsTiledLayerPtr 905 handle); 906 907 /** 908 Return the pointer to some child TiledLayer defined within a WMS-TiledLayer object 909 910 \param handle the pointer to a valid WMS-TiledLayer 911 \param index the relative index identifying the required WMS-TiledLayer (the first 912 child Layer in the WMS-TiledLayer object has index ZERO). 913 914 \return the pointer to the required WMS-TiledLayer object: NULL if the passed index 915 isn't valid 916 917 \sa get_wms_catalog_tiled_layer, wms_tiled_layer_has_children, get_wms_tiled_layer_children_count 918 */ 919 RL2_DECLARE rl2WmsTiledLayerPtr 920 get_wms_child_tiled_layer (rl2WmsTiledLayerPtr handle, int index); 921 922 /** 923 Return the name corresponding to some WMS-TiledLayer object 924 925 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 926 to get_wms_catalog_layer(). 927 928 \return the name corresponding to the WMS-TiledLayer object 929 930 \sa get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, get_wms_tiled_layer_crs, 931 get_wms_tiled_layer_format, get_wms_tiled_layer_style, get_wms_tiled_layer_pad, 932 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 933 wms_tiled_layer_has_children, get_wms_tile_pattern_count 934 */ 935 RL2_DECLARE const char *get_wms_tiled_layer_name (rl2WmsTiledLayerPtr 936 handle); 937 938 /** 939 Return the title corresponding to some WMS-TiledLayer object 940 941 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 942 to get_wms_catalog_layer(). 943 944 \return the title corresponding to the WMS-TiledLayer object 945 946 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_abstract, get_wms_tiled_layer_crs, 947 get_wms_tiled_layer_format, get_wms_tiled_layer_style, get_wms_tiled_layer_pad, 948 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 949 wms_tiled_layer_has_children, get_wms_tile_pattern_count 950 */ 951 RL2_DECLARE const char *get_wms_tiled_layer_title (rl2WmsTiledLayerPtr 952 handle); 953 954 /** 955 Return the abstract corresponding to some WMS-TiledLayer object 956 957 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 958 to get_wms_catalog_layer(). 959 960 \return the abstract corresponding to the WMS-TiledLayer object 961 962 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_crs, 963 get_wms_tiled_layer_format, get_wms_tiled_layer_style, get_wms_tiled_layer_pad, 964 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 965 wms_tiled_layer_has_children, get_wms_tile_pattern_count 966 */ 967 RL2_DECLARE const char *get_wms_tiled_layer_abstract (rl2WmsTiledLayerPtr 968 handle); 969 970 /** 971 Return the CRS corresponding to some WMS-TiledLayer object 972 973 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 974 to get_wms_catalog_layer(). 975 976 \return the CRS corresponding to the WMS-TiledLayer object 977 978 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 979 get_wms_tiled_layer_format, get_wms_tiled_layer_style, get_wms_tiled_layer_pad, 980 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 981 wms_tiled_layer_has_children 982 */ 983 RL2_DECLARE const char *get_wms_tiled_layer_crs (rl2WmsTiledLayerPtr 984 handle); 985 986 /** 987 Return the Format corresponding to some WMS-TiledLayer object 988 989 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 990 to get_wms_catalog_layer(). 991 992 \return the Format corresponding to the WMS-TiledLayer object 993 994 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 995 get_wms_tiled_layer_crs, get_wms_tiled_layer_style, get_wms_tiled_layer_pad, 996 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 997 wms_tiled_layer_has_children, get_wms_tile_pattern_count 998 */ 999 RL2_DECLARE const char *get_wms_tiled_layer_format (rl2WmsTiledLayerPtr 1000 handle); 1001 1002 /** 1003 Return the Style corresponding to some WMS-TiledLayer object 1004 1005 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1006 to get_wms_catalog_layer(). 1007 1008 \return the Style corresponding to the WMS-TiledLayer object 1009 1010 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 1011 get_wms_tiled_layer_crs, get_wms_tiled_layer_format, get_wms_tiled_layer_pad, 1012 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 1013 wms_tiled_layer_has_children, get_wms_tile_pattern_count 1014 */ 1015 RL2_DECLARE const char *get_wms_tiled_layer_style (rl2WmsTiledLayerPtr 1016 handle); 1017 1018 /** 1019 Return the Pad corresponding to some WMS-TiledLayer object 1020 1021 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1022 to get_wms_catalog_layer(). 1023 1024 \return the Pad corresponding to the WMS-TiledLayer object 1025 1026 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 1027 get_wms_tiled_layer_crs, get_wms_tiled_layer_format, get_wms_tiled_layer_style, 1028 get_wms_tiled_layer_bands, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 1029 wms_tiled_layer_has_children 1030 */ 1031 RL2_DECLARE const char *get_wms_tiled_layer_pad (rl2WmsTiledLayerPtr 1032 handle); 1033 1034 /** 1035 Return the Bands corresponding to some WMS-TiledLayer object 1036 1037 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1038 to get_wms_catalog_layer(). 1039 1040 \return the Bands corresponding to the WMS-TiledLayer object 1041 1042 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 1043 get_wms_tiled_layer_crs, get_wms_tiled_layer_format, get_wms_tiled_layer_style, 1044 get_wms_tiled_layer_pad, get_wms_tiled_layer_data_type, get_wms_tiled_layer_bbox, 1045 wms_tiled_layer_has_children, get_wms_tile_pattern_count 1046 */ 1047 RL2_DECLARE const char *get_wms_tiled_layer_bands (rl2WmsTiledLayerPtr 1048 handle); 1049 1050 /** 1051 Return the DataType corresponding to some WMS-TiledLayer object 1052 1053 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1054 to get_wms_catalog_layer(). 1055 1056 \return the DataType corresponding to the WMS-TiledLayer object 1057 1058 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, get_wms_tiled_layer_abstract, 1059 get_wms_tiled_layer_crs, get_wms_tiled_layer_format, get_wms_tiled_layer_style, 1060 get_wms_tiled_layer_pad, get_wms_tiled_layer_bands, get_wms_tiled_layer_bbox, 1061 wms_tiled_layer_has_children, get_wms_tile_pattern_count 1062 */ 1063 RL2_DECLARE const char *get_wms_tiled_layer_data_type (rl2WmsTiledLayerPtr 1064 handle); 1065 1066 /** 1067 Return the BoundingBox corresponding to some WMS-TiledLayer object 1068 1069 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1070 to get_wms_catalog_layer(). 1071 \param minx on successful completion will contain the Min Longitude 1072 \param maxx on successful completion will contain the Max Longitude 1073 \param miny on successful completion will contain the Min Latitude 1074 \param maxy on successful completion will contain the Max Latitude 1075 1076 \return 0 on error, any other value on success 1077 1078 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, 1079 get_wms_tiled_layer_abstract, get_wms_tiled_layer_crs, get_wms_tiled_layer_format, 1080 get_wms_tiled_layer_style, get_wms_tiled_layer_pad, get_wms_tiled_layer_bands, 1081 get_wms_tiled_layer_data_type, wms_tiled_layer_has_children, 1082 get_wms_tiled_layer_tile_size, get_wms_tile_pattern_count, 1083 get_wms_tile_pattern_handle 1084 */ 1085 RL2_DECLARE int get_wms_tiled_layer_bbox (rl2WmsTiledLayerPtr handle, 1086 double *minx, double *miny, 1087 double *maxx, double *maxy); 1088 1089 /** 1090 Return the Tile Size corresponding to some WMS-TiledLayer object 1091 1092 \param handle the pointer to a valid WMS-TiledLayer returned by a previous call 1093 to get_wms_catalog_layer(). 1094 \param width on successful completion will contain the Tile Width 1095 \param height on successful completion will contain the Tile Height 1096 1097 \return 0 on error, any other value on success 1098 1099 \sa get_wms_tiled_layer_name, get_wms_tiled_layer_title, 1100 get_wms_tiled_layer_abstract, get_wms_tiled_layer_crs, get_wms_tiled_layer_format, 1101 get_wms_tiled_layer_style, get_wms_tiled_layer_pad, get_wms_tiled_layer_bands, 1102 get_wms_tiled_layer_data_type, wms_tiled_layer_has_children, 1103 get_wms_tiled_layer_bbox, get_wms_tile_pattern_count, 1104 get_wms_tile_pattern_handle 1105 */ 1106 RL2_DECLARE int get_wms_tiled_layer_tile_size (rl2WmsTiledLayerPtr handle, 1107 int *width, int *height); 1108 1109 /** 1110 Return the total count of TiledPatterns defined within a WMS-TiledLayer object 1111 1112 \param handle the pointer to a valid WMS-TiledLayer 1113 1114 \return the total count of TiledPatterns defined within a WMS-TiledLayer object: 1115 a negative number if the WMS-TiledLayer isn't valid 1116 1117 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1118 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1119 get_wms_tile_pattern_base_x, get_wms_tile_pattern_base_y, 1120 get_wms_tile_pattern_extent_x, get_wms_tile_pattern_handle 1121 */ 1122 RL2_DECLARE int get_wms_tile_pattern_count (rl2WmsTiledLayerPtr handle); 1123 1124 /** 1125 Return the SRS from a TiledPattern defined within a WMS-TiledLayer object 1126 1127 \param handle the pointer to a valid WMS-TiledLayer 1128 \param index the relative index identifying the required WMS-TilePattern (the first 1129 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1130 1131 \return the SRS defined within a WMS-TilePattern object: 1132 NULL if the WMS-TilePattern isn't valid. 1133 1134 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_tile_width, 1135 get_wms_tile_pattern_tile_height, get_wms_tile_pattern_base_x, 1136 get_wms_tile_pattern_base_y, get_wms_tile_pattern_extent_x, 1137 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1138 */ 1139 RL2_DECLARE const char *get_wms_tile_pattern_srs (rl2WmsTiledLayerPtr 1140 handle, int index); 1141 1142 /** 1143 Return the TileWidth from a TiledPattern defined within a WMS-TiledLayer object 1144 1145 \param handle the pointer to a valid WMS-TiledLayer 1146 \param index the relative index identifying the required WMS-TilePattern (the first 1147 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1148 1149 \return the TileWidth defined within a WMS-TilePattern object: 1150 a negative value if the WMS-TilePattern isn't valid. 1151 1152 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1153 get_wms_tile_pattern_tile_height, get_wms_tile_pattern_base_x, 1154 get_wms_tile_pattern_base_y, get_wms_tile_pattern_extent_x, 1155 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1156 */ 1157 RL2_DECLARE int get_wms_tile_pattern_tile_width (rl2WmsTiledLayerPtr 1158 handle, int index); 1159 1160 /** 1161 Return the TileHeight from a TiledPattern defined within a WMS-TiledLayer object 1162 1163 \param handle the pointer to a valid WMS-TiledLayer 1164 \param index the relative index identifying the required WMS-TilePattern (the first 1165 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1166 1167 \return the TileHeight defined within a WMS-TilePattern object: 1168 a negative value if the WMS-TilePattern isn't valid. 1169 1170 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1171 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_base_x, 1172 get_wms_tile_pattern_base_y, get_wms_tile_pattern_extent_x, 1173 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1174 */ 1175 RL2_DECLARE int get_wms_tile_pattern_tile_height (rl2WmsTiledLayerPtr 1176 handle, int index); 1177 1178 /** 1179 Return the TileBaseX from a TiledPattern defined within a WMS-TiledLayer object 1180 1181 \param handle the pointer to a valid WMS-TiledLayer 1182 \param index the relative index identifying the required WMS-TilePattern (the first 1183 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1184 1185 \return the TileBaseX (leftmost coord) defined within a WMS-TilePattern object: 1186 DBL_MAX if the WMS-TilePattern isn't valid. 1187 1188 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1189 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1190 get_wms_tile_pattern_base_y, get_wms_tile_pattern_extent_x, 1191 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1192 */ 1193 RL2_DECLARE double get_wms_tile_pattern_base_x (rl2WmsTiledLayerPtr 1194 handle, int index); 1195 1196 /** 1197 Return the TileBaseY from a TiledPattern defined within a WMS-TiledLayer object 1198 1199 \param handle the pointer to a valid WMS-TiledLayer 1200 \param index the relative index identifying the required WMS-TilePattern (the first 1201 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1202 1203 \return the TileBaseY (topmost coord) defined within a WMS-TilePattern object: 1204 DBL_MAX if the WMS-TilePattern isn't valid. 1205 1206 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1207 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1208 get_wms_tile_pattern_base_x, get_wms_tile_pattern_extent_x, 1209 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1210 */ 1211 RL2_DECLARE double get_wms_tile_pattern_base_y (rl2WmsTiledLayerPtr 1212 handle, int index); 1213 1214 /** 1215 Return the TileExtentX from a TiledPattern defined within a WMS-TiledLayer object 1216 1217 \param handle the pointer to a valid WMS-TiledLayer 1218 \param index the relative index identifying the required WMS-TilePattern (the first 1219 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1220 1221 \return the TileExtentX defined within a WMS-TilePattern object: 1222 DBL_MAX if the WMS-TilePattern isn't valid. 1223 1224 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1225 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1226 get_wms_tile_pattern_base_x, get_wms_tile_pattern_base_y, 1227 get_wms_tile_pattern_extent_y, get_wms_tile_pattern_handle 1228 */ 1229 RL2_DECLARE double get_wms_tile_pattern_extent_x (rl2WmsTiledLayerPtr 1230 handle, int index); 1231 1232 /** 1233 Return the TileExtentY from a TiledPattern defined within a WMS-TiledLayer object 1234 1235 \param handle the pointer to a valid WMS-TiledLayer 1236 \param index the relative index identifying the required WMS-TilePattern (the first 1237 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1238 1239 \return the TileExtentX defined within a WMS-TilePattern object: 1240 DBL_MAX if the WMS-TilePattern isn't valid. 1241 1242 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1243 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1244 get_wms_tile_pattern_base_x, get_wms_tile_pattern_base_y, 1245 get_wms_tile_pattern_extent_x, get_wms_tile_pattern_handle 1246 */ 1247 RL2_DECLARE double get_wms_tile_pattern_extent_y (rl2WmsTiledLayerPtr 1248 handle, int index); 1249 1250 /** 1251 Return the handle for some TiledPattern defined within a WMS-TiledLayer object 1252 1253 \param handle the pointer to a valid WMS-TiledLayer 1254 \param pattern_index the relative index identifying the required WMS-TilePattern (the first 1255 TilePattern Layer in the WMS-TiledLayer object has index ZERO). 1256 1257 \return the handle for some TilePattern object inside 1258 a WMS-TiledLayer object: NULL if any error is encountered. 1259 1260 \sa get_wms_tile_pattern_count, get_wms_tile_pattern_srs, 1261 get_wms_tile_pattern_tile_width, get_wms_tile_pattern_tile_height, 1262 get_wms_tile_pattern_base_x, get_wms_tile_pattern_base_y, 1263 get_wms_tile_pattern_extent_x, get_wms_tile_pattern_extent_y 1264 */ 1265 RL2_DECLARE rl2WmsTilePatternPtr 1266 get_wms_tile_pattern_handle (rl2WmsTiledLayerPtr handle, int index); 1267 1268 /** 1269 Return a cloned copy of some TilePattern object 1270 1271 \param handle the pointer to a valid WMS-TilePattern returned by get_wms_tile_pattern_handle() 1272 1273 \return the handle to the new TilePattern: NULL if any error is encountered. 1274 1275 \sa get_wms_tile_pattern_handle, destroy_wms_tile_pattern, 1276 get_wms_tile_pattern_sample_url, get_wms_tile_pattern_request_url 1277 1278 \note you are responsible to destroy before or after any WMS-TilePattern 1279 object created by clone_wms_tile_pattern() by invoking destroy_wms_tile_pattern(). 1280 */ 1281 RL2_DECLARE rl2WmsTilePatternPtr 1282 clone_wms_tile_pattern (rl2WmsTilePatternPtr handle); 1283 1284 /** 1285 Destroys a cloned copy of some TilePattern object 1286 1287 \param handle the pointer to a valid WMS-TilePattern returned by clone_wms_tile_pattern_handle() 1288 1289 1290 \sa get_wms_tile_pattern_handle, clone_wms_tile_pattern, 1291 get_wms_tile_pattern_sample_url, get_wms_tile_pattern_request_url 1292 */ 1293 RL2_DECLARE void destroy_wms_tile_pattern (rl2WmsTilePatternPtr handle); 1294 1295 /** 1296 Return the sample URL representing a TiledPattern defined within a WMS-TiledLayer object 1297 1298 \param handle the pointer to a valid WMS-TilePattern returned by get_wms_tile_pattern_handle() 1299 1300 \return the sample URL representing a TilePattern object inside 1301 a WMS-TiledLayer object: NULL if any error is encountered. 1302 1303 \sa get_wms_tile_pattern_handle, clone_wms_tile_pattern, destroy_wms_tile_pattern, 1304 get_wms_tile_pattern_request_url 1305 1306 \note the returned sample URL corresponds to dynamically allocated memory, 1307 and thus requires to be deallocated by invoking sqlite3_free(). 1308 */ 1309 RL2_DECLARE char *get_wms_tile_pattern_sample_url (rl2WmsTilePatternPtr 1310 handle); 1311 1312 /** 1313 Return the full request URL for some TiledPattern defined within a WMS-TiledLayer object 1314 1315 1316 \param handle the pointer to a valid WMS-TilePattern returned by get_wms_tile_pattern_handle() 1317 1318 \return the full request URL for some TilePattern object inside 1319 a WMS-TiledLayer object: NULL if any error is encountered. 1320 1321 \sa get_wms_tile_pattern_handle, clone_wms_tile_pattern, destroy_wms_tile_pattern, 1322 , get_wms_tile_pattern_sample_url 1323 1324 \note the returned full request URL corresponds to dynamically allocated memory, 1325 and thus requires to be deallocated by invoking sqlite3_free(). 1326 */ 1327 RL2_DECLARE char *get_wms_tile_pattern_request_url (rl2WmsTilePatternPtr 1328 handle, 1329 const char *base_url, 1330 double min_x, 1331 double min_y); 1332 1333 /** 1334 Creates a WMS-Cache object 1335 1336 \return the pointer to the corresponding WMS-Cache object: NULL on failure 1337 1338 \sa destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, set_wms_cache_max_size, 1339 get_wms_cache_items_count, get_wms_cache_current_size, get_wms_cache_hit_count, 1340 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1341 1342 \note you are responsible to destroy (before or after) any WMS-Cache created by create_wms_cache(). 1343 */ 1344 RL2_DECLARE rl2WmsCachePtr create_wms_cache (void); 1345 1346 /** 1347 Destroys a WMS-Cache object freeing any allocated resource 1348 1349 \param handle the pointer to a valid WMS-Cache returned by a previous call 1350 to create_wms_cache() 1351 1352 \sa create_wms_cache, reset_wms_cache, get_wms_cache_max_size, set_wms_cache_max_size, 1353 get_wms_cache_items_count, get_wms_cache_current_size, get_wms_cache_hit_count, 1354 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1355 */ 1356 RL2_DECLARE void destroy_wms_cache (rl2WmsCachePtr handle); 1357 1358 /** 1359 Resets a WMS-Cache object to its initial empty state. 1360 1361 \param handle the pointer to a valid WMS-Cache returned by a previous call 1362 to create_wms_cache() 1363 1364 \sa create_wms_cache, destroy_wms_cache, get_wms_cache_max_size, set_wms_cache_max_size, 1365 get_wms_cache_items_count, get_wms_cache_current_size, get_wms_cache_hit_count, 1366 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1367 */ 1368 RL2_DECLARE void reset_wms_cache (rl2WmsCachePtr handle); 1369 1370 /** 1371 Return the current Max-Size from a WMS-Cache object. 1372 1373 \param handle the pointer to a valid WMS-Cache returned by a previous call 1374 to create_wms_cache() 1375 1376 \return the currently set MaxSize (in bytes) from some WMS-Cache object. 1377 1378 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, set_wms_cache_max_size, 1379 get_wms_cache_items_count, get_wms_cache_current_size, get_wms_cache_hit_count, 1380 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1381 */ 1382 RL2_DECLARE int get_wms_cache_max_size (rl2WmsCachePtr handle); 1383 1384 /** 1385 Chages the current Max Size for a WMS-Cache object. 1386 1387 \param handle the pointer to a valid WMS-Cache returned by a previous call 1388 to create_wms_cache() 1389 \param size the new Max Size (in bytes) to be set. 1390 1391 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1392 get_wms_cache_items_count, get_wms_cache_current_size, get_wms_cache_hit_count, 1393 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1394 1395 \note if the WMS-Cache currently uses more memory than allowed by the new setting 1396 any allocation in excess will be immediately freed. 1397 */ 1398 RL2_DECLARE void set_wms_cache_max_size (rl2WmsCachePtr handle, int size); 1399 1400 /** 1401 Return the current number of cached items stored within a WMS-Cache object. 1402 1403 \param handle the pointer to a valid WMS-Cache returned by a previous call 1404 to create_wms_cache() 1405 1406 \return the current number of cached items stored within a WMS-Cache object. 1407 1408 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1409 set_wms_cache_max_size, get_wms_cache_current_size, get_wms_cache_hit_count, 1410 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1411 */ 1412 RL2_DECLARE int get_wms_cache_items_count (rl2WmsCachePtr handle); 1413 1414 /** 1415 Return the current memory allocation used by a WMS-Cache object. 1416 1417 \param handle the pointer to a valid WMS-Cache returned by a previous call 1418 to create_wms_cache() 1419 1420 \return the current memory allocation (in bytes) used by a WMS-Cache object. 1421 1422 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1423 set_wms_cache_max_size, get_wms_cache_items_count, get_wms_cache_hit_count, 1424 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1425 */ 1426 RL2_DECLARE int get_wms_cache_current_size (rl2WmsCachePtr handle); 1427 1428 /** 1429 Return the current total number of cache-hit events from a WMS-Cache object. 1430 1431 \param handle the pointer to a valid WMS-Cache returned by a previous call 1432 to create_wms_cache() 1433 1434 \return the current total number of cache-hit events from a WMS-Cache object. 1435 1436 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1437 set_wms_cache_max_size, get_wms_cache_items_count, get_wms_cache_current_size, 1438 get_wms_cache_miss_count, get_wms_cache_flushed_count, get_wms_total_download_size 1439 */ 1440 RL2_DECLARE int get_wms_cache_hit_count (rl2WmsCachePtr handle); 1441 1442 /** 1443 Return the current total number of cache-miss events from a WMS-Cache object. 1444 1445 \param handle the pointer to a valid WMS-Cache returned by a previous call 1446 to create_wms_cache() 1447 1448 \return the current total number of cache-miss events from a WMS-Cache object. 1449 1450 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1451 set_wms_cache_max_size, get_wms_cache_items_count, get_wms_cache_current_size, 1452 get_wms_cache_hit_count, get_wms_cache_flushed_count, get_wms_total_download_size 1453 */ 1454 1455 RL2_DECLARE int get_wms_cache_miss_count (rl2WmsCachePtr handle); 1456 1457 /** 1458 Return the current size of memory allocations previously used by a WMS-Cache 1459 object but now definitely released. 1460 1461 \param handle the pointer to a valid WMS-Cache returned by a previous call 1462 to create_wms_cache() 1463 1464 \return the current size of memory allocations (in bytes) previously used 1465 by a WMS-Cache object but now definitely released. 1466 1467 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1468 set_wms_cache_max_size, get_wms_cache_items_count, get_wms_cache_current_size, 1469 get_wms_cache_hit_count, get_wms_cache_miss_count, get_wms_total_download_size 1470 */ 1471 RL2_DECLARE int get_wms_cache_flushed_count (rl2WmsCachePtr handle); 1472 1473 /** 1474 Return the total size (in bytes) of all cache items since the beginning of 1475 the file cycle of some WMS-Cache. 1476 1477 \param handle the pointer to a valid WMS-Cache returned by a previous call 1478 to create_wms_cache() 1479 1480 \return the total size (in bytes) of all cache items since the beginning of 1481 the file cycle of some WMS-Cache object. 1482 1483 \sa create_wms_cache, destroy_wms_cache, reset_wms_cache, get_wms_cache_max_size, 1484 set_wms_cache_max_size, get_wms_cache_items_count, get_wms_cache_current_size, 1485 get_wms_cache_hit_count, get_wms_cache_miss_count, get_wms_cache_flushed_count 1486 */ 1487 1488 RL2_DECLARE double get_wms_total_download_size (rl2WmsCachePtr handle); 1489 1490 /** 1491 Performs a WMS GetMap request - HTTP GET 1492 1493 \param handle the pointer to a valid WMS-Cache returned by a previous call 1494 to create_wms_cache() 1495 \param url the WebServive base URL. 1496 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1497 \param version a string identifying the version of the WMS protocol to be used. 1498 \param layer name of the requested WMS-Layer. 1499 \param a string identifying the CRS/SRS. 1500 \param swap_xy a boolean value used to select between normal [XY] or flipped 1501 [LatLon] axes ordering. 1502 \param minx BoundingBox: X min coordinate. 1503 \param miny BoundingBox: Y min coordinate. 1504 \param maxx BoundingBox: X max coordinate. 1505 \param maxy BoundingBox: Y max coordinate. 1506 \param width horizontal dimension (in pixels) of the requested image. 1507 \param height vertical dimension (in pixels) of the requested image. 1508 \param style a string identifying some SLD Style; could be eventually NULL. 1509 \param format a string indentifying the MIME type of the requested image. 1510 \param opaque a boolean valued used to select if the requested image 1511 should be either opaque or transparent. 1512 \param from_cache boolean value: if TRUE simply an attempt to retrieve 1513 the requested image from cached data will be performed.\n 1514 Otherwise a full HTTP request will be forwarded for any uncached request. 1515 \param err_msg on completion will contain an error message (if any) 1516 1517 \return a pointer to an RGBA buffer containing the requested image: 1518 NULL if any error is encountered. 1519 1520 \sa do_wms_GetMap_post, do_wms_GetMap_TileService_get, 1521 do_wms_GetMap_TileService_post, do_wms_GetFeatureInfo_get, 1522 do_wms_GetFeatureInfo_post 1523 1524 \note the returned RGBA corresponds to dynamically allocated memory, 1525 and thus requires to be deallocated before or after.\n 1526 An eventual error message returned via err_msg requires to be deallocated 1527 by invoking free(). 1528 */ 1529 RL2_DECLARE unsigned char *do_wms_GetMap_get (rl2WmsCachePtr handle, 1530 const char *url, 1531 const char *proxy, 1532 const char *version, 1533 const char *layer, 1534 const char *crs, int swap_xy, 1535 double minx, double miny, 1536 double maxx, double maxy, 1537 int width, int height, 1538 const char *style, 1539 const char *format, 1540 int opaque, int from_cache, 1541 char **err_msg); 1542 1543 /** 1544 Performs a WMS GetMap request - HTTP POST 1545 1546 \param handle the pointer to a valid WMS-Cache returned by a previous call 1547 to create_wms_cache() 1548 \param url the WebServive base URL. 1549 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1550 \param version a string identifying the version of the WMS protocol to be used. 1551 \param layer name of the requested WMS-Layer. 1552 \param a string identifying the CRS/SRS 1553 \param swap_xy a boolean value used to select between normal [XY] or flipped 1554 [LatLon] axes ordering. 1555 \param minx BoundingBox: X min coordinate. 1556 \param miny BoundingBox: Y min coordinate. 1557 \param maxx BoundingBox: X max coordinate. 1558 \param maxy BoundingBox: Y max coordinate. 1559 \param width horizontal dimension (in pixels) of the requested image. 1560 \param height vertical dimension (in pixels) of the requested image. 1561 \param style a string identifying some SLD Style; could be eventually NULL. 1562 \param format a string indentifying the MIME type of the requested image. 1563 \param opaque a boolean valued used to select if the requested image 1564 should be either opaque or transparent. 1565 \param from_cache boolean value: if TRUE simply an attempt to retrieve 1566 the requested image from cached data will be performed.\n 1567 Otherwise a full HTTP request will be forwarded for any uncached request. 1568 \param err_msg on completion will contain an error message (if any) 1569 1570 \return a pointer to an RGBA buffer containing the requested image: 1571 NULL if any error is encountered.\n 1572 <bCurrently unimplemented: will always return NULL</b> 1573 1574 \sa do_wms_GetMap_get, do_wms_GetMap_TileService_get, 1575 do_wms_GetMap_TileService_post, do_wms_GetFeatureInfo_get, 1576 do_wms_GetFeatureInfo_post 1577 1578 \note the returned RGBA corresponds to dynamically allocated memory, 1579 and thus requires to be deallocated before or after.\n 1580 An eventual error message returned via err_msg requires to be deallocated 1581 by invoking free(). 1582 */ 1583 RL2_DECLARE unsigned char *do_wms_GetMap_post (rl2WmsCachePtr handle, 1584 const char *url, 1585 const char *proxy, 1586 const char *version, 1587 const char *layer, 1588 const char *crs, int swap_xy, 1589 double minx, double miny, 1590 double maxx, double maxy, 1591 int width, int height, 1592 const char *style, 1593 const char *format, 1594 int opaque, int from_cache, 1595 char **err_msg); 1596 1597 /** 1598 Performs a WMS GetMap [TileService] request - HTTP GET 1599 1600 \param handle the pointer to a valid WMS-Cache returned by a previous call 1601 to create_wms_cache() 1602 \param url full TileService GetMap request URL. 1603 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1604 \param width horizontal dimension (in pixels) of the requested image. 1605 \param height vertical dimension (in pixels) of the requested image. 1606 \param from_cache boolean value: if TRUE simply an attempt to retrieve 1607 the requested image from cached data will be performed.\n 1608 Otherwise a full HTTP request will be forwarded for any uncached request. 1609 \param err_msg on completion will contain an error message (if any) 1610 1611 \return a pointer to an RGBA buffer containing the requested image: 1612 NULL if any error is encountered. 1613 1614 \sa do_wms_GetMap_get, do_wms_GetMap_post, 1615 do_wms_GetMap_TileService_post, do_wms_GetFeatureInfo_get, 1616 do_wms_GetFeatureInfo_post 1617 1618 \note the returned RGBA corresponds to dynamically allocated memory, 1619 and thus requires to be deallocated before or after.\n 1620 An eventual error message returned via err_msg requires to be deallocated 1621 by invoking free(). 1622 */ 1623 RL2_DECLARE unsigned char *do_wms_GetMap_TileService_get (rl2WmsCachePtr 1624 handle, 1625 const char *url, 1626 const char *proxy, 1627 int width, 1628 int height, 1629 int from_cache, 1630 char **err_msg); 1631 1632 /** 1633 Performs a WMS GetMap [TileService] request - HTTP POST 1634 1635 \param handle the pointer to a valid WMS-Cache returned by a previous call 1636 to create_wms_cache() 1637 \param url full TileService GetMap request URL. 1638 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1639 \param width horizontal dimension (in pixels) of the requested image. 1640 \param height vertical dimension (in pixels) of the requested image. 1641 \param from_cache boolean value: if TRUE simply an attempt to retrieve 1642 the requested image from cached data will be performed.\n 1643 Otherwise a full HTTP request will be forwarded for any uncached request. 1644 \param err_msg on completion will contain an error message (if any) 1645 1646 \return a pointer to an RGBA buffer containing the requested image: 1647 NULL if any error is encountered.\n 1648 <bCurrently unimplemented: will always return NULL</b> 1649 1650 \sa do_wms_GetMap_get, do_wms_GetMap_post, 1651 do_wms_GetMap_TileService_get, do_wms_GetFeatureInfo_get, 1652 do_wms_GetFeatureInfo_post 1653 1654 \note the returned RGBA corresponds to dynamically allocated memory, 1655 and thus requires to be deallocated before or after.\n 1656 An eventual error message returned via err_msg requires to be deallocated 1657 by invoking free(). 1658 */ 1659 RL2_DECLARE unsigned char *do_wms_GetMap_TileService_post (rl2WmsCachePtr 1660 handle, 1661 const char *url, 1662 const char 1663 *proxy, 1664 int width, 1665 int height, 1666 int from_cache, 1667 char **err_msg); 1668 1669 /** 1670 Performs a WMS GetFeatureInfo request - HTTP GET 1671 1672 \param url the WebServive base URL. 1673 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1674 \param version a string identifying the version of the WMS protocol to be used. 1675 \param format a string indentifying the MIME type of the requested image. 1676 \param layer name of the requested WMS-Layer. 1677 \param a string identifying the CRS/SRS 1678 \param swap_xy a boolean value used to select between normal [XY] or flipped 1679 [LatLon] axes ordering. 1680 \param minx BoundingBox: X min coordinate. 1681 \param miny BoundingBox: Y min coordinate. 1682 \param maxx BoundingBox: X max coordinate. 1683 \param maxy BoundingBox: Y max coordinate. 1684 \param width horizontal dimension (in pixels) of the requested image. 1685 \param height vertical dimension (in pixels) of the requested image. 1686 \param img_x X coordinate (in pixels) of the point to be queryied. 1687 \param img_y Y coordinate (in pixels) of the point to be queryied. 1688 \param err_msg on completion will contain an error message (if any) 1689 1690 \return a pointer to a WMS-FeatureCollection object: 1691 NULL if any error is encountered or if no result is available. 1692 1693 \sa do_wms_GetMap_get, do_wms_GetMap_post, do_wms_GetMap_TileService_get, 1694 do_wms_GetMap_TileService_post, do_wms_GetFeatureInfo_post, 1695 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1696 get_wms_feature_members_count 1697 1698 \note the returned WMS-FeatureCollection corresponds to dynamically allocated memory, 1699 and thus requires to be deallocated before or after by invoking destroy_wms_feature_collection().\n 1700 An eventual error message returned via err_msg requires to be deallocated 1701 by invoking free(). 1702 */ 1703 RL2_DECLARE rl2WmsFeatureCollectionPtr 1704 do_wms_GetFeatureInfo_get (const char *url, 1705 const char *proxy, 1706 const char *version, 1707 const char *format, 1708 const char *layer, 1709 const char *crs, 1710 int swap_xy, 1711 double minx, 1712 double miny, 1713 double maxx, 1714 double maxy, 1715 int width, int height, 1716 int img_x, int img_y, char **err_msg); 1717 1718 /** 1719 Performs a WMS GetFeatureInfo request - HTTP POST 1720 1721 \param url the WebServive base URL. 1722 \param proxy an optional HTTP Proxy string: could be eventually NULL. 1723 \param version a string identifying the version of the WMS protocol to be used. 1724 \param format a string indentifying the MIME type of the requested image. 1725 \param layer name of the requested WMS-Layer. 1726 \param a string identifying the CRS/SRS 1727 \param swap_xy a boolean value used to select between normal [XY] or flipped 1728 [LatLon] axes ordering. 1729 \param minx BoundingBox: X min coordinate. 1730 \param miny BoundingBox: Y min coordinate. 1731 \param maxx BoundingBox: X max coordinate. 1732 \param maxy BoundingBox: Y max coordinate. 1733 \param width horizontal dimension (in pixels) of the requested image. 1734 \param height vertical dimension (in pixels) of the requested image. 1735 \param img_x X coordinate (in pixels) of the point to be queried. 1736 \param img_y Y coordinate (in pixels) of the point to be queried. 1737 \param err_msg on completion will contain an error message (if any) 1738 1739 \return a pointer to a WMS-FeatureCollection object: 1740 NULL if any error is encountered or if no result is available.\n 1741 <bCurrently unimplemented: will always return NULL</b> 1742 1743 \sa do_wms_GetMap_get, do_wms_GetMap_post, do_wms_GetMap_TileService_get, 1744 do_wms_GetMap_TileService_post, do_wms_GetFeatureInfo_get, 1745 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1746 get_wms_feature_members_count 1747 1748 \note the returned WMS-FeatureCollection corresponds to dynamically allocated memory, 1749 and thus requires to be deallocated before or after by invoking destroy_wms_feature_collection().\n 1750 An eventual error message returned via err_msg requires to be deallocated 1751 by invoking free(). 1752 */ 1753 RL2_DECLARE rl2WmsFeatureCollectionPtr 1754 do_wms_GetFeatureInfo_post (const char *url, 1755 const char *proxy, 1756 const char *version, 1757 const char *format, 1758 const char *layer, 1759 const char *crs, 1760 int swap_xy, 1761 double minx, 1762 double miny, 1763 double maxx, 1764 double maxy, 1765 int width, int height, 1766 int img_x, int img_y, char **err_msg); 1767 1768 /** 1769 Destroys a WMS-FeatureCollection object freeing any allocated resource 1770 1771 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1772 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1773 1774 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1775 wms_feature_collection_parse_geometries, get_wms_feature_members_count, 1776 get_wms_feature_member, get_wms_feature_attributes_count, 1777 get_wms_feature_attribute_name, get_wms_feature_attribute_value, 1778 get_wms_feature_attribute_geometry 1779 */ 1780 RL2_DECLARE void destroy_wms_feature_collection (rl2WmsFeatureCollectionPtr 1781 handle); 1782 1783 /** 1784 Attempts to parse all GML Geometries from within a WMS-FeatureCollection object 1785 1786 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1787 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1788 \param srid the SRID value of the current Map 1789 \param point_x X coordinate (in the Map CRS) identifying the queried Point. 1790 \param point_y Y coordinate (in the Map CRS) identifying the queried Point. 1791 \param sqlite handle to a valid SQLite connection - required in order to support 1792 coordinate re-projections based on ST_Transform(). 1793 1794 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1795 destroy_wms_feature_collection, get_wms_feature_members_count, 1796 get_wms_feature_member, get_wms_feature_attributes_count, 1797 get_wms_feature_attribute_name, get_wms_feature_attribute_value, 1798 get_wms_feature_attribute_geometry 1799 */ 1800 RL2_DECLARE void 1801 wms_feature_collection_parse_geometries (rl2WmsFeatureCollectionPtr 1802 handle, int srid, 1803 double point_x, double point_y, 1804 sqlite3 * sqlite); 1805 1806 /** 1807 Return the total count of WMS-FeatureMembers from within a WMS_FeatureCollection object 1808 1809 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1810 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1811 1812 \return the total count of WMS-FeatureMembers from within a WMS_FeatureCollection object. 1813 1814 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1815 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1816 get_wms_feature_member, get_wms_feature_attributes_count, 1817 get_wms_feature_attribute_name, get_wms_feature_attribute_value, 1818 get_wms_feature_attribute_geometry 1819 */ 1820 RL2_DECLARE int get_wms_feature_members_count (rl2WmsFeatureCollectionPtr 1821 handle); 1822 1823 /** 1824 Return a pointer referencing the Nth WMS-FeatureMember from within a WMS_FeatureCollection object 1825 1826 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1827 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1828 \param index the relative index identifying the required FeatureMember (the first 1829 Member supported by a WMS-FeatureCollection object has index ZERO). 1830 1831 \return a pointer referencing the Nth WMS-FeatureMember from within a WMS_FeatureCollection 1832 object: NULL for empty/void collections or if any error occurs. 1833 1834 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1835 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1836 get_wms_feature_member, get_wms_feature_attributes_count, 1837 get_wms_feature_attribute_name, get_wms_feature_attribute_value, 1838 get_wms_feature_attribute_geometry 1839 */ 1840 RL2_DECLARE rl2WmsFeatureMemberPtr 1841 get_wms_feature_member (rl2WmsFeatureCollectionPtr handle, int index); 1842 1843 /** 1844 Return a pointer the Name string of some WMS-FeatureMember object 1845 1846 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1847 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1848 1849 \return a pointer the Name string of some WMS-FeatureMember object: 1850 NULL if any error occurs. 1851 1852 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1853 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1854 get_wms_feature_member, get_wms_feature_attributes_count, 1855 get_wms_feature_attribute_name, get_wms_feature_attribute_value, 1856 get_wms_feature_attribute_geometry 1857 */ 1858 RL2_DECLARE int get_wms_feature_attributes_count (rl2WmsFeatureMemberPtr 1859 handle); 1860 1861 /** 1862 Return a pointer the Nth AttributeName string from within some WMS-FeatureMember object 1863 1864 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1865 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1866 \param index the relative index identifying the required Attribute (the first 1867 Attribute supported by a WMS-FeatureMember object has index ZERO). 1868 1869 \return a pointer the Nth AttributeName string of some WMS-FeatureMember object: 1870 NULL if any error occurs. 1871 1872 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1873 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1874 get_wms_feature_member, get_wms_feature_attributes_count, 1875 get_wms_feature_attributes_count, get_wms_feature_attribute_value, 1876 get_wms_feature_attribute_geometry 1877 */ 1878 RL2_DECLARE const char 1879 *get_wms_feature_attribute_name (rl2WmsFeatureMemberPtr handle, 1880 int index); 1881 1882 /** 1883 Return a pointer the Nth AttributeValue string from within some WMS-FeatureMember object 1884 1885 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1886 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1887 \param index the relative index identifying the required Attribute (the first 1888 Attribute supported by a WMS-FeatureMember object has index ZERO). 1889 1890 \return a pointer the Nth AttributeValue string of some WMS-FeatureMember object: 1891 NULL if any error occurs. (please note: an AttributeValue could eventually correspond 1892 to a NULL value by itself) 1893 1894 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1895 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1896 get_wms_feature_member, get_wms_feature_attributes_count, 1897 get_wms_feature_attributes_count, get_wms_feature_attribute_name, 1898 get_wms_feature_attribute_geometry 1899 */ 1900 RL2_DECLARE const char 1901 *get_wms_feature_attribute_value (rl2WmsFeatureMemberPtr handle, 1902 int index); 1903 1904 /** 1905 Return a pointer to a SpatiaLite's own Geometry object corresponding to the Nth AttributeValue 1906 from within some WMS-FeatureMember object 1907 1908 \param handle the pointer to a valid WMS-FeatureCollection returned by a previous call 1909 to do_wms_GetFeatureInfo_get() or do_wms_GetFeatureInfo_post() 1910 \param index the relative index identifying the required Attribute (the first 1911 Attribute supported by a WMS-FeatureMember object has index ZERO). 1912 1913 \return a pointer the Nth AttributeValue of some WMS-FeatureMember object if it actually 1914 corresponds to some GML Geometry: 1915 NULL if any error occurs or if the AttributeValue isn't a GML Geometry. 1916 1917 \sa do_wms_GetFeatureInfo_get, do_wms_GetFeatureInfo_post, 1918 destroy_wms_feature_collection, wms_feature_collection_parse_geometries, 1919 get_wms_feature_member, get_wms_feature_attributes_count, 1920 get_wms_feature_attributes_count, get_wms_feature_attribute_name, 1921 get_wms_feature_attribute_value 1922 1923 \note the returned Geometry object simply is a reference, and this must 1924 absolutely not be destroyed by directly calling gaiaFreeGeomColl(). 1925 */ 1926 RL2_DECLARE gaiaGeomCollPtr 1927 get_wms_feature_attribute_geometry (rl2WmsFeatureMemberPtr handle, 1928 int index); 1929 1930 #ifdef __cplusplus 1931 } 1932 #endif 1933 1934 #endif /* RL2WMS_H */ 1935