Changeset 15865 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2020-02-16T22:29:06+01:00 (5 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/gui/io/importexport/GeoJSONImporter.java
r15588 r15865 33 33 34 34 private static final ExtensionFileFilter FILE_FILTER = ExtensionFileFilter.newFilterWithArchiveExtensions( 35 "geojson ,json", "geojson", tr("GeoJSON file") + " (*.geojson, *.geojson.gz, *.geojson.bz2, *.geojson.xz, *.geojson.zip, *.json)",35 "geojson", "geojson", tr("GeoJSON file") + " (*.geojson, *.geojson.gz, *.geojson.bz2, *.geojson.xz, *.geojson.zip)", 36 36 ExtensionFileFilter.AddArchiveExtension.NONE, Arrays.asList("gz", "bz", "bz2", "xz", "zip")); 37 37 -
trunk/src/org/openstreetmap/josm/io/GeoJSONReader.java
r15785 r15865 74 74 private void parseRoot(final JsonObject object) throws IllegalDataException { 75 75 parseCrs(object.getJsonObject(CRS)); 76 switch (object.getString(TYPE)) { 76 switch (Optional.ofNullable(object.getJsonString(TYPE)) 77 .orElseThrow(() -> new IllegalDataException("No type")).getString()) { 77 78 case "FeatureCollection": 78 79 parseFeatureCollection(object.getJsonArray(FEATURES));
Note:
See TracChangeset
for help on using the changeset viewer.