@@ -32,13 +32,9 @@ class SharedData
3232 }
3333
3434 // ---- Read all config details from JSON file
35- // TODO: should be able to get cachedGeometryNames and indices from osmObject,
36- // rather than needing them to be passed as parameters
3735
3836 void readConfig (rapidjson::Document &jsonConfig, bool hasClippingBox, Box &clippingBox,
39- map< uint, vector<OutputObject> > &tileIndex,
40- map< uint, string > &cachedGeometryNames,
41- map< string, RTree > &indices) {
37+ map< uint, vector<OutputObject> > &tileIndex) {
4238 baseZoom = jsonConfig[" settings" ][" basezoom" ].GetUint ();
4339 startZoom = jsonConfig[" settings" ][" minzoom" ].GetUint ();
4440 endZoom = jsonConfig[" settings" ][" maxzoom" ].GetUint ();
@@ -108,11 +104,11 @@ class SharedData
108104 }
109105 bool indexed=false ; if (it->value .HasMember (" index" )) {
110106 indexed=it->value [" index" ].GetBool ();
111- indices[layerName] =RTree ();
107+ osmObject. indices -> operator [](layerName) =RTree ();
112108 }
113109 string indexName = it->value .HasMember (" index_column" ) ? it->value [" index_column" ].GetString () : " " ;
114110 readShapefile (it->value [" source" ].GetString (), sourceColumns, clippingBox, tileIndex,
115- cachedGeometries, cachedGeometryNames, baseZoom, layerNum, layerName, indexed, indices, indexName);
111+ cachedGeometries, *osmObject. cachedGeometryNames , baseZoom, layerNum, layerName, indexed, *osmObject. indices , indexName);
116112 }
117113 }
118114 }
0 commit comments