-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
184 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
69 changes: 69 additions & 0 deletions
69
src/main/java/neqsim/util/exception/InvalidOutputException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
package neqsim.util.exception; | ||
|
||
/** | ||
* <p> | ||
* InvalidOutputException class. | ||
* </p> | ||
* | ||
* @author Even Solbraa | ||
* @version $Id: $Id | ||
*/ | ||
public class InvalidOutputException extends neqsim.util.exception.ThermoException { | ||
private static final long serialVersionUID = 1000; | ||
|
||
/** | ||
* Constructs an <code>InvalidOutputException</code> with the specified detail message. | ||
* | ||
* @param msg the detail message. | ||
*/ | ||
@Deprecated | ||
public InvalidOutputException(String msg) { | ||
super(msg); | ||
} | ||
|
||
/** | ||
* Constructs an <code>InvalidOutputException</code> with a default message. | ||
* | ||
* @param className Class that exception is raised from | ||
* @param methodName Method that exception is raised from | ||
* @param outputName Name of invalid output | ||
*/ | ||
public InvalidOutputException(String className, String methodName, String outputName) { | ||
super(className, methodName, "output " + outputName + " was invalid."); | ||
} | ||
|
||
/** | ||
* Constructs an <code>InvalidOutputException</code> with the specified detail message. | ||
* | ||
* @param className Class that exception is raised from | ||
* @param methodName Method that exception is raised from | ||
* @param outputName Name of invalid output | ||
* @param msg error message detailing output problem | ||
*/ | ||
public InvalidOutputException(String className, String methodName, String outputName, String msg) { | ||
super(className, methodName, "output " + outputName + " " + msg); | ||
} | ||
|
||
/** | ||
* Constructs an <code>InvalidOutputException</code> with a default message. | ||
* | ||
* @param obj Object that exception is raised from | ||
* @param methodName Method that exception is raised from | ||
* @param outputName Name of invalid output | ||
*/ | ||
public InvalidOutputException(Object obj, String methodName, String outputName) { | ||
this(obj.getClass().getSimpleName(), methodName, outputName); | ||
} | ||
|
||
/** | ||
* Constructs an <code>InvalidOutputException</code> with a default message. | ||
* | ||
* @param obj Object that exception is raised from | ||
* @param methodName Method that exception is raised from | ||
* @param outputName Name of invalid output | ||
* @param msg error message detailing output problem | ||
*/ | ||
public InvalidOutputException(Object obj, String methodName, String outputName, String msg) { | ||
this(obj.getClass().getSimpleName(), methodName, outputName, msg); | ||
} | ||
} |
Oops, something went wrong.