|
acm.util
Class ErrorException
java.lang.Object
|
+--java.lang.Throwable
|
+--java.lang.Exception
|
+--java.lang.RuntimeException
|
+--acm.util.ErrorException
public class ErrorException extends RuntimeException
This class allows errors to be reported in a consistent way.
Clients typically call
throw new ErrorException(msg);
Because ErrorException is a subclass of RuntimeException,
this exception need not be declared in throws clauses.
public ErrorException(Exception ex)
- Creates an ErrorException using an existing exception.
-
Usage: | throw new ErrorException(ex); |
Parameter: |
ex | The exception to be reported
|
|
public ErrorException(String msg)
- Creates an ErrorException with the specified message.
-
Usage: | throw new ErrorException(msg); |
Parameter: |
msg | The error message to be reported
|
|
|