Package org.codehaus.groovy
Class GroovyBugError
- java.lang.Object
- 
- java.lang.Throwable
- 
- java.lang.Error
- 
- java.lang.AssertionError
- 
- org.codehaus.groovy.GroovyBugError
 
 
 
 
- 
- All Implemented Interfaces:
- java.io.Serializable
 
 public class GroovyBugError extends java.lang.AssertionErrorThis class represents an error that is thrown when a bug is recognized inside the runtime. Basically it is thrown when a constraint is not fulfilled that should be fulfilled.- See Also:
- Serialized Form
 
- 
- 
Constructor SummaryConstructors Constructor Description GroovyBugError(java.lang.Exception exception)Constructs a bug error using the given exceptionGroovyBugError(java.lang.String message)constructs a bug error using the given textGroovyBugError(java.lang.String msg, java.lang.Exception exception)Constructs a bug error using the given exception and a text with additional information about the cause
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetBugText()Returns the bug text to describe this errorjava.lang.ThrowablegetCause()java.lang.StringgetMessage()Returns the detail message string of this error.voidsetBugText(java.lang.String msg)Sets the bug text to describe this errorjava.lang.StringtoString()Returns a String representation of this class by callinggetMessage().
 
- 
- 
- 
Constructor Detail- 
GroovyBugErrorpublic GroovyBugError(java.lang.String message) constructs a bug error using the given text- Parameters:
- message- the error message text
 
 - 
GroovyBugErrorpublic GroovyBugError(java.lang.Exception exception) Constructs a bug error using the given exception- Parameters:
- exception- cause of this error
 
 - 
GroovyBugErrorpublic GroovyBugError(java.lang.String msg, java.lang.Exception exception)Constructs a bug error using the given exception and a text with additional information about the cause- Parameters:
- msg- additional information about this error
- exception- cause of this error
 
 
- 
 - 
Method Detail- 
toStringpublic java.lang.String toString() Returns a String representation of this class by callinggetMessage().- Overrides:
- toStringin class- java.lang.Throwable
- See Also:
- getMessage()
 
 - 
getMessagepublic java.lang.String getMessage() Returns the detail message string of this error. The message will consist of the bug text prefixed by "BUG! " if there this instance was created using a message. If this error was constructed without using a bug text the message of the cause is used prefixed by "BUG! UNCAUGHT EXCEPTION: "- Overrides:
- getMessagein class- java.lang.Throwable
- Returns:
- the detail message string of this error.
 
 - 
getCausepublic java.lang.Throwable getCause() - Overrides:
- getCausein class- java.lang.Throwable
 
 - 
getBugTextpublic java.lang.String getBugText() Returns the bug text to describe this error
 - 
setBugTextpublic void setBugText(java.lang.String msg) Sets the bug text to describe this error
 
- 
 
-