class DefaultErrorsPrinter extends DefaultStackTracePrinter implements CodeSnippetPrinter
Default implementation of the StackTracePrinter interface.
Type | Name and description |
---|---|
ResourceLocator |
resourceLocator |
Constructor and description |
---|
DefaultErrorsPrinter() |
DefaultErrorsPrinter(ResourceLocator resourceLocator) |
Type Params | Return Type | Name and description |
---|---|---|
|
String |
formatCodeSnippetEnd(Resource resource, int lineNumber) |
|
protected String |
formatCodeSnippetErrorLine(int currentLineNumber, Object currentLine) |
|
protected String |
formatCodeSnippetLine(int currentLineNumber, Object currentLine) |
|
String |
formatCodeSnippetStart(Resource resource, int lineNumber) |
|
protected String |
getFileName(StackTraceElement te) |
|
protected Resource |
getFileNameInfo(Throwable cause, Resource res) |
|
protected int |
getLineNumberInfo(Throwable cause, int defaultInfo) |
|
protected Throwable |
getRootCause(Throwable ex) Obtains the root cause of the given exception |
|
String |
prettyPrintCodeSnippet(Throwable exception) |
Methods inherited from class | Name |
---|---|
class DefaultStackTracePrinter |
getFileName, makeRelativeIfPossible, prettyPrint, printCausedByMessage, printFailureLocation, printHeader, printLastEntry, printStackLine, shouldSkipNextCause |
Obtains the root cause of the given exception
ex
- The exception