Hi all!
Attached is a patch that provides a way of retrieving the
nested exception/error from org.apache.turbine.util.TurbineException
and org.apache.turbine.util.TurbineRuntimeException.
William
Index: TurbineException.java
===================================================================
RCS file:
/home/cvspublic/jakarta-turbine-2/src/java/org/apache/turbine/util/TurbineException.java,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 TurbineException.java
--- TurbineException.java 16 Aug 2001 05:09:43 -0000 1.1.1.1
+++ TurbineException.java 6 Jun 2002 04:21:25 -0000
@@ -177,6 +177,16 @@
super(msg);
this.nested = nested;
}
+
+ /**
+ * Returns the nested exception or error that caused this exception.
+ *
+ * @return The nested throwable object, or <b>null</b> if it was not
+ * saved.
+ */
+ public Throwable getNested() {
+ return nested;
+ }
/**
* Returns the error message of this and any nested <code>Throwable</code>.
Index: TurbineRuntimeException.java
===================================================================
RCS file:
/home/cvspublic/jakarta-turbine-2/src/java/org/apache/turbine/util/TurbineRuntimeException.java,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 TurbineRuntimeException.java
--- TurbineRuntimeException.java 16 Aug 2001 05:09:43 -0000 1.1.1.1
+++ TurbineRuntimeException.java 6 Jun 2002 04:21:26 -0000
@@ -128,6 +128,16 @@
super(msg);
this.nested = nested;
}
+
+ /**
+ * Returns the nested exception or error that caused this exception.
+ *
+ * @return The nested throwable object, or <b>null</b> if it was not
+ * saved.
+ */
+ public Throwable getNested() {
+ return nested;
+ }
/**
* Prints the stack trace of this exception the the standar error
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>