aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiri Vanek <[email protected]>2013-09-18 15:54:12 +0200
committerJiri Vanek <[email protected]>2013-09-18 15:54:12 +0200
commit82ddca8f769b7ac53ed7db695c9ff1976da77471 (patch)
treeb87223ae87fde0dba256e9c8b4db549d4abcfd42
parent69c42197274a390fa8e364941c6e28a0a09a6d36 (diff)
Removed java 1.3 comaptible (redundant) code from ParseException
netx/net/sourceforge/jnlp/ParseException.java: (ParseException) modified to support super call only, (getCause) and both (printStackTrace) removed
-rw-r--r--ChangeLog7
-rw-r--r--netx/net/sourceforge/jnlp/ParseException.java45
2 files changed, 10 insertions, 42 deletions
diff --git a/ChangeLog b/ChangeLog
index b261ac3..3398768 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2013-09-18 Jiri Vanek <[email protected]>
+
+ Removed java 1.3 comaptible (redundant) code from ParseException
+ * netx/net/sourceforge/jnlp/ParseException.java: (ParseException)
+ modified to support super call only, (getCause) and both (printStackTrace)
+ removed
+
2013-09-16 Andrew Azores <[email protected]>
Fix ResourcesTest reproducer.
diff --git a/netx/net/sourceforge/jnlp/ParseException.java b/netx/net/sourceforge/jnlp/ParseException.java
index ce7e23b..a98603a 100644
--- a/netx/net/sourceforge/jnlp/ParseException.java
+++ b/netx/net/sourceforge/jnlp/ParseException.java
@@ -30,9 +30,7 @@ public class ParseException extends Exception {
// todo: add meaningful information, such as the invalid
// element, parse position, etc.
- /** the original exception */
- private Throwable cause = null;
-
+
/**
* Create a parse exception with the specified message.
*/
@@ -45,44 +43,7 @@ public class ParseException extends Exception {
* cause.
*/
public ParseException(String message, Throwable cause) {
- super(message);
-
- // replace with setCause when no longer 1.3 compatible
- this.cause = cause;
- }
-
- /**
- * Return the cause of the launch exception or null if there
- * is no cause exception.
- */
- public Throwable getCause() {
- return cause;
- }
-
- /**
- * Print the stack trace and the cause exception (1.3
- * compatible)
- */
- public void printStackTrace(PrintStream stream) {
- super.printStackTrace(stream);
-
- if (cause != null) {
- stream.println("Caused by: ");
- cause.printStackTrace(stream);
- }
- }
-
- /**
- * Print the stack trace and the cause exception (1.3
- * compatible)
- */
- public void printStackTrace(PrintWriter stream) {
- super.printStackTrace(stream);
-
- if (cause != null) {
- stream.println("Caused by: ");
- cause.printStackTrace(stream);
- }
- }
+ super(message, cause);
+ }
}