|
|||||||||||||||||||
| 30 day Evaluation Version distributed via the Maven Jar Repository. Clover is not free. You have 30 days to evaluate it. Please visit http://www.thecortex.net/clover to obtain a licensed version of Clover | |||||||||||||||||||
| Source file | Conditionals | Statements | Methods | TOTAL | |||||||||||||||
| NestedRuntimeException.java | - | 20% | 20% | 20% |
|
||||||||||||||
| 1 |
/**
|
|
| 2 |
* JFoxSOAF, Service-Oriented Application Framework
|
|
| 3 |
*
|
|
| 4 |
* Copyright (C) www.huihoo.org
|
|
| 5 |
*
|
|
| 6 |
* Distributable under GNU LGPL license
|
|
| 7 |
*
|
|
| 8 |
* For more information, please visit: http://www.huihoo.org/jfox/jfoxsoaf
|
|
| 9 |
*/
|
|
| 10 |
|
|
| 11 |
package org.huihoo.jfox.soaf.exception;
|
|
| 12 |
|
|
| 13 |
/**
|
|
| 14 |
* Superclass for all unchecked Exceptions in JFoxSOAF.
|
|
| 15 |
*
|
|
| 16 |
* @author <a href="mailto:founder_chen@yahoo.com.cn">Peter Cheng </a>
|
|
| 17 |
* @version $Revision: 1.1 $ $Date: 2004/10/20 07:23:15 $
|
|
| 18 |
* @version Revision: 1.0
|
|
| 19 |
*/
|
|
| 20 |
|
|
| 21 |
public class NestedRuntimeException extends RuntimeException { |
|
| 22 |
|
|
| 23 |
/**
|
|
| 24 |
* The exception that caused this one.
|
|
| 25 |
*/
|
|
| 26 |
private Throwable cause;
|
|
| 27 |
|
|
| 28 |
/**
|
|
| 29 |
* Construct a new exception with no cause and no detail message. Note
|
|
| 30 |
* modern JVMs may still track the exception that caused this one.
|
|
| 31 |
*/
|
|
| 32 | 0 |
protected NestedRuntimeException() {
|
| 33 |
} |
|
| 34 |
|
|
| 35 |
/**
|
|
| 36 |
* Construct a new exception with no cause and the specified detail message.
|
|
| 37 |
* Note modern JVMs may still track the exception that caused this one.
|
|
| 38 |
*
|
|
| 39 |
* @param message
|
|
| 40 |
* the message detailing the exception.
|
|
| 41 |
*/
|
|
| 42 | 0 |
protected NestedRuntimeException(final String message) {
|
| 43 | 0 |
super(message);
|
| 44 |
} |
|
| 45 |
|
|
| 46 |
/**
|
|
| 47 |
* Construct a new exception with the specified cause and no detail message.
|
|
| 48 |
*
|
|
| 49 |
* @param cause
|
|
| 50 |
* the exception that caused this one.
|
|
| 51 |
*/
|
|
| 52 | 3 |
protected NestedRuntimeException(final Throwable cause) {
|
| 53 | 3 |
this.cause = cause;
|
| 54 |
} |
|
| 55 |
|
|
| 56 |
/**
|
|
| 57 |
* Construct a new exception with the specified cause and the specified
|
|
| 58 |
* detail message.
|
|
| 59 |
*
|
|
| 60 |
* @param message
|
|
| 61 |
* the message detailing the exception.
|
|
| 62 |
* @param cause
|
|
| 63 |
* the exception that caused this one.
|
|
| 64 |
*/
|
|
| 65 | 0 |
protected NestedRuntimeException(final String message, final Throwable cause) {
|
| 66 | 0 |
super(message);
|
| 67 | 0 |
this.cause = cause;
|
| 68 |
} |
|
| 69 |
|
|
| 70 |
/**
|
|
| 71 |
* Retrieve the exception that caused this one.
|
|
| 72 |
*
|
|
| 73 |
* @return the exception that caused this one, or null if it was not set.
|
|
| 74 |
* @see Throwable#getCause() the method available since JDK 1.3 that is
|
|
| 75 |
* overridden by this method.
|
|
| 76 |
*/
|
|
| 77 | 0 |
public Throwable getCause() {
|
| 78 | 0 |
return cause;
|
| 79 |
} |
|
| 80 |
|
|
| 81 |
} |
|
||||||||||