public class GroovyRuntimeException
extends RuntimeException
An exception thrown by the interpreter
| Constructor and description |
|---|
GroovyRuntimeException()Creates an empty runtime exception. |
GroovyRuntimeException(String message)Creates a runtime exception with the supplied message. |
GroovyRuntimeException(String message, ASTNode node)Creates a runtime exception with the supplied message and AST node. |
GroovyRuntimeException(String message, Throwable cause)Creates a runtime exception with the supplied message and cause. |
GroovyRuntimeException(Throwable t)Creates a runtime exception with the supplied cause. |
| Type Params | Return Type | Name and description |
|---|---|---|
|
protected String |
getLocationText()Builds the source-location suffix appended to this exception's message when location data is available. |
|
public String |
getMessage()Returns the message including location information when available. |
|
public String |
getMessageWithoutLocationText()Returns the detail message without appended location information. |
|
public ModuleNode |
getModule()Returns the related module, if any. |
|
public ASTNode |
getNode()Returns the related AST node, if any. |
|
public void |
setModule(ModuleNode module)Sets the module used when reporting location information. |
| Methods inherited from class | Name |
|---|---|
class RuntimeException |
addSuppressed, equals, fillInStackTrace, getCause, getClass, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, hashCode, initCause, notify, notifyAll, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString, wait, wait, wait |
Creates an empty runtime exception.
Creates a runtime exception with the supplied message.
message - the detail messageCreates a runtime exception with the supplied message and AST node.
message - the detail messagenode - the related AST nodeCreates a runtime exception with the supplied message and cause.
message - the detail messagecause - the underlying causeCreates a runtime exception with the supplied cause.
t - the underlying causeBuilds the source-location suffix appended to this exception's message when location data is available.
Returns the message including location information when available.
Returns the detail message without appended location information.
Returns the related module, if any.
Returns the related AST node, if any.
Sets the module used when reporting location information.
module - the related moduleCopyright © 2003-2026 The Apache Software Foundation. All rights reserved.