Groovy Documentation

org.codehaus.groovy.grails.exceptions
[Groovy] Interface StackTracePrinter


interface StackTracePrinter

Defines method for pretty printing Stack traces.

Authors:
Graeme Rocher
Since:
2.0


Method Summary
java.lang.String prettyPrint(java.lang.Throwable throwable)

Pretty print the given stack trace and return the result

java.lang.String prettyPrintCodeSnippet(java.lang.Throwable exception)

Attempts to present a preview code snippet of the code that went wrong

 

Method Detail

prettyPrint

java.lang.String prettyPrint(java.lang.Throwable throwable)
Pretty print the given stack trace and return the result
Parameters:
throwable - The throwable
Returns:
The result


prettyPrintCodeSnippet

java.lang.String prettyPrintCodeSnippet(java.lang.Throwable exception)
Attempts to present a preview code snippet of the code that went wrong
Parameters:
exception - The exception
Returns:
The code snippet or nothing if it can't be previewed


 

Groovy Documentation