Groovy Documentation

org.codehaus.groovy.grails.web.errors
[Java] Class GrailsWrappedRuntimeException

java.lang.Object
  java.lang.Throwable
      java.lang.Exception
          java.lang.RuntimeException
              org.codehaus.groovy.grails.exceptions.GrailsException
                  org.codehaus.groovy.grails.web.errors.GrailsWrappedRuntimeException

public class GrailsWrappedRuntimeException
extends GrailsException

Wraps a Grails RuntimeException and attempts to extract more relevent diagnostic messages from the stack trace.

Authors:
Graeme Rocher
Since:
0.1


Field Summary
static java.lang.String URL_PREFIX

 
Constructor Summary
GrailsWrappedRuntimeException(ServletContext servletContext, java.lang.Throwable t)

@param servletContext The ServletContext instance

 
Method Summary
java.lang.String getClassName()

@return Returns the className.

String[] getCodeSnippet()

@return Returns the line.

int getLineNumber()

@return Returns the lineNumber.

java.lang.String getMessage()

String[] getStackTraceLines()

@return Returns the stackTrace lines

java.lang.String getStackTraceText()

@return Returns the stackTrace.

 
Methods inherited from class java.lang.RuntimeException
java.lang.RuntimeException#printStackTrace(java.io.PrintStream), java.lang.RuntimeException#printStackTrace(), java.lang.RuntimeException#printStackTrace(java.io.PrintWriter), java.lang.RuntimeException#fillInStackTrace(), java.lang.RuntimeException#getCause(), java.lang.RuntimeException#initCause(java.lang.Throwable), java.lang.RuntimeException#toString(), java.lang.RuntimeException#getMessage(), java.lang.RuntimeException#getLocalizedMessage(), java.lang.RuntimeException#getStackTrace(), java.lang.RuntimeException#setStackTrace([Ljava.lang.StackTraceElement;), java.lang.RuntimeException#wait(), java.lang.RuntimeException#wait(long), java.lang.RuntimeException#wait(long, int), java.lang.RuntimeException#equals(java.lang.Object), java.lang.RuntimeException#hashCode(), java.lang.RuntimeException#getClass(), java.lang.RuntimeException#notify(), java.lang.RuntimeException#notifyAll()
 
Methods inherited from class java.lang.Exception
java.lang.Exception#printStackTrace(java.io.PrintStream), java.lang.Exception#printStackTrace(), java.lang.Exception#printStackTrace(java.io.PrintWriter), java.lang.Exception#fillInStackTrace(), java.lang.Exception#getCause(), java.lang.Exception#initCause(java.lang.Throwable), java.lang.Exception#toString(), java.lang.Exception#getMessage(), java.lang.Exception#getLocalizedMessage(), java.lang.Exception#getStackTrace(), java.lang.Exception#setStackTrace([Ljava.lang.StackTraceElement;), java.lang.Exception#wait(), java.lang.Exception#wait(long), java.lang.Exception#wait(long, int), java.lang.Exception#equals(java.lang.Object), java.lang.Exception#hashCode(), java.lang.Exception#getClass(), java.lang.Exception#notify(), java.lang.Exception#notifyAll()
 
Methods inherited from class java.lang.Throwable
java.lang.Throwable#printStackTrace(java.io.PrintStream), java.lang.Throwable#printStackTrace(), java.lang.Throwable#printStackTrace(java.io.PrintWriter), java.lang.Throwable#fillInStackTrace(), java.lang.Throwable#getCause(), java.lang.Throwable#initCause(java.lang.Throwable), java.lang.Throwable#toString(), java.lang.Throwable#getMessage(), java.lang.Throwable#getLocalizedMessage(), java.lang.Throwable#getStackTrace(), java.lang.Throwable#setStackTrace([Ljava.lang.StackTraceElement;), java.lang.Throwable#wait(), java.lang.Throwable#wait(long), java.lang.Throwable#wait(long, int), java.lang.Throwable#equals(java.lang.Object), java.lang.Throwable#hashCode(), java.lang.Throwable#getClass(), java.lang.Throwable#notify(), java.lang.Throwable#notifyAll()
 
Methods inherited from class java.lang.Object
java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()
 

Field Detail

URL_PREFIX

public static final java.lang.String URL_PREFIX


 
Constructor Detail

GrailsWrappedRuntimeException

public GrailsWrappedRuntimeException(ServletContext servletContext, java.lang.Throwable t)
Parameters:
servletContext - The ServletContext instance
t - The exception that was thrown


 
Method Detail

getClassName

public java.lang.String getClassName()
Returns:
Returns the className.


getCodeSnippet

public String[] getCodeSnippet()
Returns:
Returns the line.


getLineNumber

public int getLineNumber()
Returns:
Returns the lineNumber.


getMessage

@Override
public java.lang.String getMessage()


getStackTraceLines

public String[] getStackTraceLines()
Returns:
Returns the stackTrace lines


getStackTraceText

public java.lang.String getStackTraceText()
Returns:
Returns the stackTrace.


 

Groovy Documentation