Changeset 30990 in osm for applications/editors/josm


Ignore:
Timestamp:
2015-02-15T19:32:00+01:00 (10 years ago)
Author:
donvip
Message:

[josm_reverter] fix #josm1083 - robustness to revert of redacted objects

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/reverter/src/reverter/OsmServerMultiObjectReader.java

    r30436 r30990  
    1010import org.openstreetmap.josm.data.osm.PrimitiveId;
    1111import org.openstreetmap.josm.gui.progress.ProgressMonitor;
     12import org.openstreetmap.josm.io.IllegalDataException;
    1213import org.openstreetmap.josm.io.OsmServerReader;
    1314import org.openstreetmap.josm.io.OsmTransferException;
     
    1617public class OsmServerMultiObjectReader extends OsmServerReader {
    1718    private final MultiOsmReader rdr = new MultiOsmReader();
    18    
     19
    1920    public void readObject(PrimitiveId id, int version, ProgressMonitor progressMonitor) throws OsmTransferException {
    2021        readObject(id.getUniqueId(), version, id.getType(), progressMonitor);
    2122    }
    22    
     23
    2324    public void readObject(long id,int version,OsmPrimitiveType type,ProgressMonitor progressMonitor) throws OsmTransferException {
    2425        StringBuffer sb = new StringBuffer();
     
    3132        try (InputStream in = getInputStream(sb.toString(), progressMonitor.createSubTaskMonitor(1, true))) {
    3233            rdr.addData(in);
    33         } catch (Exception e) {
     34        } catch (IOException | IllegalDataException e) {
    3435            throw new OsmTransferException(e);
    3536        } finally {
Note: See TracChangeset for help on using the changeset viewer.