public class UserError extends RuntimeException
RuntimeException so that it can be thrown from locations that would not allow a
checked exception (like the run() method of the Runnable
interface).| Modifier and Type | Field and Description |
|---|---|
static String |
defaultFormat |
static String |
formatKey |
| Constructor and Description |
|---|
UserError(String msg)
Construct a
UserError with the supplied error message. |
| Modifier and Type | Method and Description |
|---|---|
void |
printStackTrace()
Print the stack trace for this error.
|
void |
printStackTrace(PrintStream ps)
Print the stack trace for this error to a specified
PrintStream. |
void |
printStackTrace(PrintWriter pw)
Print the stack trace for this error to a specified
PrintWriter. |
String |
toString()
Create a
String representation of the UserError. |
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, setStackTracepublic static final String formatKey
public static final String defaultFormat
public UserError(String msg)
UserError with the supplied error message.msg - the error messagepublic void printStackTrace()
printStackTrace in class Throwablepublic void printStackTrace(PrintStream ps)
PrintStream. This method
overrides the default behaviour to output only the error line and not
the stack trace.printStackTrace in class Throwableps - the PrintStreampublic void printStackTrace(PrintWriter pw)
PrintWriter. This method
overrides the default behaviour to output only the error line and not
the stack trace.printStackTrace in class Throwablepw - the PrintWriterCopyright © 2020. All rights reserved.