MCPcopy Create free account
hub / github.com/MapServer/MapServer / msWFSLayerNextShape

Function msWFSLayerNextShape

mapwfslayer.c:936–967  ·  view source on GitHub ↗

* msWFSLayerGetNextShape() * **********************************************************************/

Source from the content-addressed store, hash-verified

934 *
935 **********************************************************************/
936int msWFSLayerNextShape(layerObj *layer, shapeObj *shape)
937{
938#ifdef USE_WFS_LYR
939 msWFSLayerInfo* psInfo = NULL;
940
941 if(layer != NULL && layer->wfslayerinfo != NULL)
942 psInfo = (msWFSLayerInfo*)layer->wfslayerinfo;
943 else
944 {
945 msSetError(MS_WFSERR, "Layer is not opened.", "msWFSLayerNextShape()");
946 return MS_FAILURE;
947 }
948
949 if(psInfo->bLayerHasValidGML)
950 return msOGRLayerNextShape(layer, shape);
951 else
952 {
953 /* Layer is successful, but there is no data to process */
954 msFreeShape(shape);
955 shape->type = MS_SHAPE_NULL;
956 return MS_FAILURE;
957 }
958#else
959/* ------------------------------------------------------------------
960 * WFS CONNECTION Support not included...
961 * ------------------------------------------------------------------ */
962 msSetError(MS_WFSCONNERR, "WFS CLIENT CONNECTION support is not available.",
963 "msWFSLayerNextShape()");
964 return(MS_FAILURE);
965#endif /* USE_WFS_LYR */
966
967}
968
969/**********************************************************************
970 * msWFSLayerGetExtent()

Callers

nothing calls this directly

Calls 3

msSetErrorFunction · 0.85
msOGRLayerNextShapeFunction · 0.85
msFreeShapeFunction · 0.85

Tested by

no test coverage detected