The base exception class for Jervis from which all other exceptions derive.
To run this example, clone Jervis and execute ./gradlew console to bring up a Groovy Console with the classpath set up.
import net.gleske.jervis.exceptions.JervisException
throw new JervisException('some text')
// or alternately catch and re-throw with documentation
try {
// some code which throws an exception
} catch(JervisException ex) {
throw new JervisException('See docs at https://example.com/', ex)
}
| Constructor and description |
|---|
JervisException
(String message)Throw a JervisException. |
JervisException
(String message, Throwable t)Throw a reduced JervisException attaching an additional message to the exception. |
| Methods inherited from class | Name |
|---|---|
class Exception |
printStackTrace, printStackTrace, printStackTrace, getStackTrace, fillInStackTrace, getCause, initCause, toString, getMessage, getSuppressed, getLocalizedMessage, setStackTrace, addSuppressed, equals, hashCode, getClass, notify, notifyAll, wait, wait, wait |
class Throwable |
printStackTrace, printStackTrace, printStackTrace, getStackTrace, fillInStackTrace, getCause, initCause, toString, getMessage, getSuppressed, getLocalizedMessage, setStackTrace, addSuppressed, equals, hashCode, getClass, notify, notifyAll, wait, wait, wait |
Throw a JervisException.
message - A simple message.Jervis API documentation.