|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.groovy.tools.ErrorReporter
Provides services for reporting compilation errors to the
user. Primary entry point is write()
.
Constructor Summary | |
ErrorReporter(java.lang.Throwable e)
Configures a new Reporter. |
|
ErrorReporter(java.lang.Throwable e,
boolean debug)
Configures a new Reporter. |
Method Summary | |
protected void |
cleanup()
Cleans up any state information after a write() operation. |
protected void |
dispatch(java.lang.Throwable object,
boolean child)
Runs the report once all initialization is complete. |
protected java.lang.String |
eol()
Returns the end-of-line marker. |
protected void |
println(java.lang.String line)
Prints a line to the underlying PrintStream |
protected void |
println(java.lang.StringBuffer line)
|
protected java.lang.String |
repeatString(java.lang.String pattern,
int repeats)
Returns a string made up of repetitions of the specified string. |
protected void |
report(CompilationFailuresException e,
boolean child)
For CompilationFailuresException. |
protected void |
report(CompilerBugException e,
boolean child)
For CompilerBugException. |
protected void |
report(java.lang.Exception e,
boolean child)
For Exception. |
protected void |
report(ExceptionCollector e,
boolean child)
For ExceptionCollector. |
protected void |
report(GroovyException e,
boolean child)
For GroovyException. |
protected void |
report(SyntaxException e,
boolean child)
For SyntaxException. |
protected void |
report(java.lang.Throwable e,
boolean child)
For everything else. |
protected void |
setSource(java.lang.String path)
Sets the source, closing any old source. |
void |
setSources(java.util.Map sources)
Allows you to supply a map of String sources, if sources aren't files. |
protected void |
stacktrace(java.lang.Throwable e,
boolean always)
Displays an exception's stack trace, if debug or
always . |
void |
write(java.io.PrintStream stream)
Writes the error to the specified PrintStream . |
void |
write(java.io.PrintWriter writer)
Writes the error to the specified PrintWriter . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ErrorReporter(java.lang.Throwable e)
e
- the exception on which to reportpublic ErrorReporter(java.lang.Throwable e, boolean debug)
e
- the exception on which to reportdebug
- if set, stack traces will be output for all reportsMethod Detail |
public void setSources(java.util.Map sources)
Compiler
when storing an ExceptionCollector
in the CompilationFailuresException
.
public void write(java.io.PrintStream stream)
PrintStream
.
public void write(java.io.PrintWriter writer)
PrintWriter
.
protected void dispatch(java.lang.Throwable object, boolean child)
protected void report(CompilationFailuresException e, boolean child)
protected void report(ExceptionCollector e, boolean child)
protected void report(SyntaxException e, boolean child)
protected void report(CompilerBugException e, boolean child)
protected void report(GroovyException e, boolean child)
protected void report(java.lang.Exception e, boolean child)
protected void report(java.lang.Throwable e, boolean child)
protected void println(java.lang.String line)
PrintStream
protected void println(java.lang.StringBuffer line)
protected void stacktrace(java.lang.Throwable e, boolean always)
debug
or
always
.
protected java.lang.String repeatString(java.lang.String pattern, int repeats)
protected java.lang.String eol()
protected void setSource(java.lang.String path)
protected void cleanup()
write()
operation.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |