Ignore:
Timestamp:
2017-12-17T01:25:46+01:00 (2 years ago)
Author:
Don-vip
Message:

enable PMD rule PreserveStackTrace + add missing jars to run new PMD rule designer

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

Legend:

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

    r12620 r13207  
    9898
    9999    /**
    100      * Creates the exception with the given error header and the given
    101      * source.
     100     * Creates the exception with the given error header and source.
    102101     *
    103102     * @param errorHeader the error header
     
    105104     */
    106105    public ChangesetClosedException(String errorHeader, Source source) {
    107         super(errorHeader);
     106        this(errorHeader, source, null);
     107    }
     108
     109    /**
     110     * Creates the exception with the given error header, source and cause.
     111     *
     112     * @param errorHeader the error header
     113     * @param source the source for the exception
     114     * @param cause  The cause (which is saved for later retrieval by the {@link #getCause} method).
     115     *               A null value is permitted, and indicates that the cause is nonexistent or unknown.
     116     * @since 13207
     117     */
     118    public ChangesetClosedException(String errorHeader, Source source, Throwable cause) {
     119        super(errorHeader, cause);
    108120        parseErrorHeader(errorHeader);
    109121        this.source = source == null ? Source.UNSPECIFIED : source;
  • trunk/src/org/openstreetmap/josm/io/OsmApi.java

    r12992 r13207  
    487487            String errorHeader = e.getErrorHeader();
    488488            if (e.getResponseCode() == HttpURLConnection.HTTP_CONFLICT && ChangesetClosedException.errorHeaderMatchesPattern(errorHeader))
    489                 throw new ChangesetClosedException(errorHeader, ChangesetClosedException.Source.UPDATE_CHANGESET);
     489                throw new ChangesetClosedException(errorHeader, ChangesetClosedException.Source.UPDATE_CHANGESET, e);
    490490            throw e;
    491491        } finally {
Note: See TracChangeset for help on using the changeset viewer.