Changeset 36092 in osm for applications/editors/josm/plugins/opendata/src
- Timestamp:
- 2023-05-30T22:06:15+02:00 (18 months ago)
- Location:
- applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/datasets/be/BelgianDataSetHandler.java
r36072 r36092 35 35 36 36 protected class InternalCsvHandler extends DefaultCsvHandler { 37 /*@Override38 public List<Projection> getSpreadSheetProjections() {39 if (singleProjection != null) {40 return Arrays.asList(new Projection[]{singleProjection});41 } else {42 return Arrays.asList(projections);43 }44 }*/45 46 37 @Override 47 38 public LatLon getCoor(EastNorth en, String[] fields) { -
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/datasets/fr/FrenchDataSetHandler.java
r36072 r36092 48 48 49 49 protected class InternalCsvHandler extends DefaultCsvHandler { 50 /*@Override51 public List<Projection> getSpreadSheetProjections() {52 if (singleProjection != null) {53 return Arrays.asList(new Projection[]{singleProjection});54 } else {55 return Arrays.asList(projections);56 }57 }*/58 59 50 @Override 60 51 public LatLon getCoor(EastNorth en, String[] fields) { -
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/io/archive/CandidateChooser.java
r36072 r36092 67 67 } 68 68 69 /*public List<File> getSelectedFiles() {70 List<File> result = new ArrayList<File>();71 for (JCheckBox cbox : checkBoxes.keySet()) {72 if (cbox.isSelected()) {73 result.add(checkBoxes.get(cbox));74 }75 }76 return result;77 }*/78 79 69 public File getSelectedFile() { 80 70 return (File) fileCombo.getSelectedItem(); -
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/io/geographic/MifReader.java
r36072 r36092 68 68 69 69 private Projection josmProj; 70 private DataSet d s;70 private DataSet dataSet; 71 71 private Relation region; 72 72 private Way polygon; … … 381 381 382 382 private void parseData(String[] words) { 383 if (d s== null) {384 d s= new DataSet();383 if (dataSet == null) { 384 dataSet = new DataSet(); 385 385 } 386 386 } … … 392 392 private void parseLine(String[] words) throws IOException { 393 393 Way line = new Way(); 394 d s.addPrimitive(line);394 dataSet.addPrimitive(line); 395 395 readAttributes(line); 396 396 line.addNode(createNode(words[1], words[2])); … … 401 401 Way previousPolyline = polyline; 402 402 polyline = new Way(); 403 d s.addPrimitive(polyline);403 dataSet.addPrimitive(polyline); 404 404 if (initial) { 405 405 readAttributes(polyline); … … 431 431 region = new Relation(); 432 432 region.put("type", "multipolygon"); 433 d s.addPrimitive(region);433 dataSet.addPrimitive(region); 434 434 readAttributes(region); 435 435 } else { … … 488 488 initializeReaders(in, file, cs, 1); 489 489 parseHeader(); 490 return d s;490 return dataSet; 491 491 } finally { 492 492 if (midReader != null) { … … 520 520 } else if (words[0].equalsIgnoreCase("Data")) { 521 521 parseData(words); 522 } else if (d s!= null) {522 } else if (dataSet != null) { 523 523 if (state == State.START_POLYGON) { 524 524 numpts = Integer.parseInt(words[0]); 525 525 polygon = new Way(); 526 d s.addPrimitive(polygon);526 dataSet.addPrimitive(polygon); 527 527 if (region != null) { 528 528 region.addMember(new RelationMember("outer", polygon)); … … 629 629 private Node createNode(String x, String y) { 630 630 Node node = new Node(josmProj.eastNorth2latlon(new EastNorth(Double.parseDouble(x), Double.parseDouble(y)))); 631 d s.addPrimitive(node);631 dataSet.addPrimitive(node); 632 632 return node; 633 633 } -
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/io/geographic/TabFiles.java
r36072 r36092 111 111 for (Entry<ShpFileType, URL> entry : entries) { 112 112 if (!exists(entry.getKey())) { 113 url = findExistingFile(entry.get Key(), entry.getValue());113 url = findExistingFile(entry.getValue()); 114 114 if (url != null) { 115 115 toUpdate.put(entry.getKey(), url); … … 121 121 } 122 122 123 private URL findExistingFile( ShpFileType shpFileType,URL value) {123 private URL findExistingFile(URL value) { 124 124 final File file = URLs.urlToFile(value); 125 125 File directory = file.getParentFile(); -
applications/editors/josm/plugins/opendata/src/org/openstreetmap/josm/plugins/opendata/core/licenses/License.java
r36072 r36092 14 14 public abstract class License { 15 15 16 public static final ODbL ODbL= new ODbL();17 public static final LOOL LOOL= new LOOL();16 public static final ODbL odbl = new ODbL(); 17 public static final LOOL lool = new LOOL(); 18 18 19 19 private final Map<String, URL> urls = new HashMap<>();
Note:
See TracChangeset
for help on using the changeset viewer.