donaldp 02/03/30 13:31:37
Modified: event/src/java/org/apache/avalon/excalibur/event
SinkException.java
Log:
Remove dependency on CascadingThrowable and friends
Revision Changes Path
1.3 +32 -6
jakarta-avalon-excalibur/event/src/java/org/apache/avalon/excalibur/event/SinkException.java
Index: SinkException.java
===================================================================
RCS file:
/home/cvs/jakarta-avalon-excalibur/event/src/java/org/apache/avalon/excalibur/event/SinkException.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- SinkException.java 16 Mar 2002 00:05:46 -0000 1.2
+++ SinkException.java 30 Mar 2002 21:31:37 -0000 1.3
@@ -7,22 +7,48 @@
*/
package org.apache.avalon.excalibur.event;
-import org.apache.avalon.framework.CascadingException;
-
/**
* A SourceException is thrown when an enqueue operation fails.
*
* @author <a href="mailto:[EMAIL PROTECTED]">Berin Loritsch</a>
*/
-public class SinkException extends CascadingException
+public class SinkException
+ extends Exception
{
- public SinkException( String message )
+ /**
+ * The Throwable that caused this exception to be thrown.
+ */
+ private final Throwable m_throwable;
+
+ /**
+ * Construct a new <code>SinkException</code> instance.
+ *
+ * @param message The detail message for this exception.
+ */
+ public SinkException( final String message )
+ {
+ this( message, null );
+ }
+
+ /**
+ * Construct a new <code>SinkException</code> instance.
+ *
+ * @param message The detail message for this exception.
+ * @param throwable the root cause of the exception
+ */
+ public SinkException( final String message, final Throwable throwable )
{
super( message );
+ m_throwable = throwable;
}
- public SinkException( String message, Throwable e )
+ /**
+ * Retrieve root cause of the exception.
+ *
+ * @return the root cause
+ */
+ public final Throwable getCause()
{
- super( message, e );
+ return m_throwable;
}
}
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>