changed db-tag-processing to csv-file

This commit is contained in:
Arndt Brenschede 2023-07-03 08:24:42 +02:00
parent c109caac2a
commit 18f2cb548f
3 changed files with 6 additions and 6 deletions

View file

@ -112,8 +112,8 @@ public class OsmCutter extends MapCreatorBase {
return "records read: " + recordCnt + " nodes=" + nodesParsed + " ways=" + waysParsed + " rels=" + relsParsed + " changesets=" + changesetsParsed; return "records read: " + recordCnt + " nodes=" + nodesParsed + " ways=" + waysParsed + " rels=" + relsParsed + " changesets=" + changesetsParsed;
} }
public void setJdbcUrl(String url) { public void setDbTagFilename(String filename) {
dbPseudoTagProvider = new DatabasePseudoTagProvider(url); dbPseudoTagProvider = new DatabasePseudoTagProvider(filename);
} }
@Override @Override

View file

@ -13,7 +13,7 @@ public class OsmFastCutter extends MapCreatorBase {
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
System.out.println("*** OsmFastCutter: cut an osm map in node-tiles + way-tiles"); System.out.println("*** OsmFastCutter: cut an osm map in node-tiles + way-tiles");
if (args.length != 11 && args.length != 12 && args.length != 13) { if (args.length != 11 && args.length != 12 && args.length != 13) {
String common = "java OsmFastCutter <lookup-file> <node-dir> <way-dir> <node55-dir> <way55-dir> <border-file> <out-rel-file> <out-res-file> <filter-profile> <report-profile> <check-profile> <map-file> [jdbc-url]"; String common = "java OsmFastCutter <lookup-file> <node-dir> <way-dir> <node55-dir> <way55-dir> <border-file> <out-rel-file> <out-res-file> <filter-profile> <report-profile> <check-profile> <map-file> [db-tag-filename]";
System.out.println("usage: bzip2 -dc <map> | " + common); System.out.println("usage: bzip2 -dc <map> | " + common);
System.out.println("or : " + common + " <inputfile> "); System.out.println("or : " + common + " <inputfile> ");
@ -37,10 +37,10 @@ public class OsmFastCutter extends MapCreatorBase {
); );
} }
public static void doCut(File lookupFile, File nodeDir, File wayDir, File node55Dir, File way55Dir, File borderFile, File relFile, File resFile, File profileAll, File profileReport, File profileCheck, File mapFile, String jdbcurl) throws Exception { public static void doCut(File lookupFile, File nodeDir, File wayDir, File node55Dir, File way55Dir, File borderFile, File relFile, File resFile, File profileAll, File profileReport, File profileCheck, File mapFile, String dbTagFilename) throws Exception {
// **** run OsmCutter **** // **** run OsmCutter ****
OsmCutter cutter = new OsmCutter(); OsmCutter cutter = new OsmCutter();
if (jdbcurl != null) cutter.setJdbcUrl(jdbcurl); if (dbTagFilename != null) cutter.setDbTagFilename(dbTagFilename);
// ... inject WayCutter // ... inject WayCutter
cutter.wayCutter = new WayCutter(); cutter.wayCutter = new WayCutter();

View file

@ -35,7 +35,7 @@ public class MapcreatorTest {
File profileCheck = new File(profileDir, "softaccess.brf"); File profileCheck = new File(profileDir, "softaccess.brf");
File borderFile = new File(tmpdir, "bordernids.dat"); File borderFile = new File(tmpdir, "bordernids.dat");
new OsmFastCutter().doCut(lookupFile, nodes, ways, nodes55, ways55, borderFile, relFile, resFile, profileAll, profileReport, profileCheck, mapFile, null); OsmFastCutter.doCut(lookupFile, nodes, ways, nodes55, ways55, borderFile, relFile, resFile, profileAll, profileReport, profileCheck, mapFile, null);
// run PosUnifier // run PosUnifier