MCPcopy Index your code
hub / github.com/MapServer/MapServer / msWCSGetCapabilities_CoverageOfferingBrief

Function msWCSGetCapabilities_CoverageOfferingBrief

mapwcs.c:852–894  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

850/************************************************************************/
851
852static int msWCSGetCapabilities_CoverageOfferingBrief(layerObj *layer, wcsParamsObj *params)
853{
854 coverageMetadataObj cm;
855 int status;
856
857 if((layer->status == MS_DELETE) || !msWCSIsLayerSupported(layer)) return MS_SUCCESS; /* not an error, this layer cannot be served via WCS */
858
859 status = msWCSGetCoverageMetadata(layer, &cm);
860 if(status != MS_SUCCESS) return MS_FAILURE;
861
862 /* start the CoverageOfferingBrief section */
863 msIO_printf(" <CoverageOfferingBrief>\n"); /* is this tag right? (I hate schemas without ANY examples) */
864
865 /* optional metadataLink */
866 msOWSPrintURLType(stdout, &(layer->metadata), "CO", "metadatalink",
867 OWS_NOERR,
868 " <metadataLink%s%s%s%s xlink:type=\"simple\"%s/>",
869 NULL, " metadataType=\"%s\"", NULL, NULL, NULL,
870 " xlink:href=\"%s\"", MS_FALSE, MS_FALSE, MS_FALSE,
871 MS_FALSE, MS_TRUE, "other", NULL, NULL, NULL, NULL, NULL);
872
873 msOWSPrintEncodeMetadata(stdout, &(layer->metadata), "CO", "description", OWS_NOERR, " <description>%s</description>\n", NULL);
874 msOWSPrintEncodeMetadata(stdout, &(layer->metadata), "CO", "name", OWS_NOERR, " <name>%s</name>\n", layer->name);
875
876 msOWSPrintEncodeMetadata(stdout, &(layer->metadata), "CO", "label", OWS_WARN, " <label>%s</label>\n", NULL);
877
878 /* TODO: add elevation ranges to lonLatEnvelope (optional) */
879 msIO_printf(" <lonLatEnvelope srsName=\"urn:ogc:def:crs:OGC:1.3:CRS84\">\n");
880 msIO_printf(" <gml:pos>%.15g %.15g</gml:pos>\n", cm.llextent.minx, cm.llextent.miny); /* TODO: don't know if this is right */
881 msIO_printf(" <gml:pos>%.15g %.15g</gml:pos>\n", cm.llextent.maxx, cm.llextent.maxy);
882
883 msOWSPrintEncodeMetadataList(stdout, &(layer->metadata), "CO", "timeposition", NULL, NULL, " <gml:timePosition>%s</gml:timePosition>\n", NULL);
884
885 msIO_printf(" </lonLatEnvelope>\n");
886
887 /* we are not supporting the optional keyword type, at least not yet */
888 msOWSPrintEncodeMetadataList(stdout, &(layer->metadata), "CO", "keywordlist", " <keywords>\n", " </keywords>\n", " <keyword>%s</keyword>\n", NULL);
889
890 /* done */
891 msIO_printf(" </CoverageOfferingBrief>\n");
892
893 return MS_SUCCESS;
894}
895
896/************************************************************************/
897/* msWCSGetCapabilities_ContentMetadata() */

Callers 1

Calls 6

msWCSIsLayerSupportedFunction · 0.85
msWCSGetCoverageMetadataFunction · 0.85
msIO_printfFunction · 0.85
msOWSPrintURLTypeFunction · 0.85
msOWSPrintEncodeMetadataFunction · 0.85

Tested by

no test coverage detected