Ignore:
Timestamp:
2017-03-19T02:26:34+01:00 (8 years ago)
Author:
Don-vip
Message:

PMD - Strict Exceptions

Location:
trunk/src/org/openstreetmap/josm/io
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/BoundingBoxDownloader.java

    r11397 r11746  
    1717import org.openstreetmap.josm.gui.progress.ProgressMonitor;
    1818import org.openstreetmap.josm.tools.CheckParameterUtil;
     19import org.openstreetmap.josm.tools.JosmRuntimeException;
    1920import org.xml.sax.SAXException;
    2021
     
    114115        } catch (OsmTransferException e) {
    115116            throw e;
    116         } catch (RuntimeException e) {
     117        } catch (JosmRuntimeException | IllegalStateException e) {
    117118            if (cancel)
    118119                return null;
  • trunk/src/org/openstreetmap/josm/io/NameFinder.java

    r11620 r11746  
    241241                Main.error(ex); // SAXException does not chain correctly
    242242                throw new SAXException(ex.getMessage(), ex);
    243             } catch (NullPointerException ex) {
     243            } catch (NullPointerException ex) { // NOPMD
    244244                Main.error(ex); // SAXException does not chain correctly
    245245                throw new SAXException(tr("Null pointer exception, possibly some missing tags."), ex);
  • trunk/src/org/openstreetmap/josm/io/NmeaReader.java

    r11620 r11746  
    415415            return true;
    416416
    417         } catch (RuntimeException ex) {
     417        } catch (IllegalArgumentException | IndexOutOfBoundsException ex) {
    418418            // out of bounds and such
    419419            Main.debug(ex);
  • trunk/src/org/openstreetmap/josm/io/remotecontrol/handler/ImportHandler.java

    r10212 r11746  
    4747                }
    4848            }
    49         } catch (RuntimeException ex) {
     49        } catch (RuntimeException ex) { // NOPMD
    5050            Main.warn("RemoteControl: Error parsing import remote control request:");
    5151            Main.error(ex);
  • trunk/src/org/openstreetmap/josm/io/remotecontrol/handler/LoadAndZoomHandler.java

    r10657 r11746  
    146146                }
    147147            }
    148         } catch (RuntimeException ex) {
     148        } catch (RuntimeException ex) { // NOPMD
    149149            Main.warn("RemoteControl: Error parsing load_and_zoom remote control request:");
    150150            Main.error(ex);
Note: See TracChangeset for help on using the changeset viewer.