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

Function loadCluster

mapfile.c:2291–2325  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2289}
2290
2291int loadCluster(clusterObj *cluster) {
2292 for(;;) {
2293 switch(msyylex()) {
2294 case(CLUSTER):
2295 break; /* for string loads */
2296 case(MAXDISTANCE):
2297 if(getDouble(&(cluster->maxdistance)) == -1) return(-1);
2298 break;
2299 case(BUFFER):
2300 if(getDouble(&(cluster->buffer)) == -1) return(-1);
2301 break;
2302 case(REGION):
2303 if(getString(&cluster->region) == MS_FAILURE) return(-1);
2304 break;
2305 case(END):
2306 return(0);
2307 break;
2308 case(GROUP):
2309 if(loadExpression(&(cluster->group)) == -1) return(-1);
2310 break;
2311 case(FILTER):
2312 if(loadExpression(&(cluster->filter)) == -1) return(-1);
2313 break;
2314 default:
2315 if(strlen(msyystring_buffer) > 0) {
2316 msSetError(MS_IDENTERR, "Parsing error near (%s):(line %d)", "loadCluster()", msyystring_buffer, msyylineno);
2317 return(-1);
2318 } else {
2319 return(0); /* end of a string, not an error */
2320 }
2321
2322 }
2323 }
2324 return(MS_SUCCESS);
2325}
2326
2327int msUpdateClusterFromString(clusterObj *cluster, char *string)
2328{

Callers 2

loadLayerFunction · 0.85

Calls 4

getDoubleFunction · 0.85
getStringFunction · 0.85
loadExpressionFunction · 0.85
msSetErrorFunction · 0.85

Tested by

no test coverage detected