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

Function msDBFGetItemIndexes

mapxbase.c:885–903  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

883}
884
885int *msDBFGetItemIndexes(DBFHandle dbffile, char **items, int numitems)
886{
887 int *itemindexes=NULL, i;
888
889 if(numitems == 0) return(NULL);
890
891 itemindexes = (int *)malloc(sizeof(int)*numitems);
892 MS_CHECK_ALLOC(itemindexes, sizeof(int)*numitems, NULL);
893
894 for(i=0;i<numitems;i++) {
895 itemindexes[i] = msDBFGetItemIndex(dbffile, items[i]);
896 if(itemindexes[i] == -1) {
897 free(itemindexes);
898 return(NULL); /* item not found */
899 }
900 }
901
902 return(itemindexes);
903}
904
905char **msDBFGetValueList(DBFHandle dbffile, int record, int *itemindexes, int numitems)
906{

Callers 2

msSHPLayerInitItemInfoFunction · 0.85

Calls 1

msDBFGetItemIndexFunction · 0.85

Tested by

no test coverage detected