8 #include "../../src/terralib/ws/ogc/wms/client/XMLParser.h" 9 #include "../../src/terralib/common/TerraLib.h" 10 #include "../../src/terralib/qt/af/ApplicationController.h" 11 #include "../../src/terralib/ws/ogc/wms/client/WMSClient.h" 13 #include <QApplication> 15 int main(
int argc,
char *argv[])
27 std::string version =
"1.3.0";
30 std::string url =
"http://terrabrasilis.info/terraamazon/ows";
33 std::cout <<
"GetCapabilities Example." << std::endl;
43 std::vector<te::ws::ogc::wms::Layer> childLayers = rootLayer.
m_layers;
45 for(
size_t i = 0; i < childLayers.size(); i++)
49 std::cout <<
"Layer Info" << std::endl;
51 std::cout <<
"Layer Name: " << childLayer.
m_name << std::endl;
52 std::cout <<
"Layer Title: " << childLayer.
m_title << std::endl;
54 std::cout <<
"Layer Possible Bounding Boxes" << std::endl;
60 std::cout <<
"BoundingBox CRS: " << bbox.
m_crs << std::endl;
61 std::cout <<
"minx: " << bbox.
m_minX << std::endl;
62 std::cout <<
"maxx: " << bbox.
m_maxX << std::endl;
63 std::cout <<
"minx: " << bbox.
m_minX << std::endl;
64 std::cout <<
"maxy: " << bbox.
m_maxY << std::endl;
67 for(
size_t j = 0; j < childLayer.
m_styles.size(); j++)
71 std::cout <<
"Style: " << style.
m_name << std::endl;
75 std::cout <<
"============================" << std::endl;
80 std::cout <<
"GetMap Example." << std::endl;
90 std::vector<te::ws::ogc::wms::Layer> childLayers = rootLayer.
m_layers;
114 std::cout <<
"Buffer Size: " << response.
m_size << std::endl;
115 std::cout <<
"Buffer Format: " << response.
m_format << std::endl;
118 std::cout <<
"============================" << std::endl;
121 std::cout <<
"GetFeatureInfo Example." << std::endl;
131 std::vector<te::ws::ogc::wms::Layer> childLayers = rootLayer.
m_layers;
164 std::cout <<
"Feature Info Format: " << response.
m_infoFormat << std::endl;
std::vector< std::string > m_layers
const te::ws::ogc::wms::WMSGetMapResponse getMap(const te::ws::ogc::wms::WMSGetMapRequest &request) const
Return the WMSGetMapResponse member.
const te::ws::ogc::wms::WMSCapabilities & getCapabilities() const
Return the WMSCapabilities member.
int main(int argc, char *argv[])
std::vector< std::string > m_queryLayers
This XML Schema Document named xlinks xsd has been stored here based on the change request
WMSGetMapRequest m_getMap
std::vector< Layer > m_layers
OnlineResource m_onlineResource
The Capability WMS 1.3.0 struct.
void finalize()
It finalizes the TerraLib Platform.
static TerraLib & getInstance()
It returns a reference to the singleton instance.
std::vector< std::string > m_styles
BoundingBox m_boundingBox
te::da::DataSourceCapabilities capabilities
std::vector< Style > m_styles
The WMSGetFeatureInfoRequest WMS 1.3.0 struct.
The Layer WMS 1.3.0 struct.
The WMSGetMapResponse WMS 1.3.0 struct.
The WMSGetMapResponse WMS 1.3.0 struct.
const te::ws::ogc::wms::WMSGetFeatureInfoResponse getFeatureInfo(const te::ws::ogc::wms::WMSGetFeatureInfoRequest &request) const
It execute a WMS GetFeatureInfo and returns a WMSGetFeatureInfoResponse with the result.
void initialize()
It initializes the TerraLib Platform.
The Style WMS 1.3.0 struct.
void updateCapabilities()
Method to get the capabilities from a WMS server and store in m_capabilities member.
A class to retrieve information and data from a Web Map Service.
std::vector< BoundingBox > m_boundingBoxes
std::string m_featureInfoContent
The WMSGetMapRequest WMS 1.3.0 struct.
The BoundingBox WMS 1.3.0 struct.