|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.google.javascript.rhino.SimpleErrorReporter
public class SimpleErrorReporter
A simple ErrorReporter that collects warnings and errors and makes
them accessible via errors() and warnings().
| Constructor Summary | |
|---|---|
SimpleErrorReporter()
|
|
| Method Summary | |
|---|---|
void |
error(String message,
String sourceName,
int line,
int lineOffset)
Report an error. |
List<String> |
errors()
Returns the list of errors, or null if there were none. |
static String |
getMessage0(String messageId)
|
static String |
getMessage1(String messageId,
Object arg1)
|
void |
warning(String message,
String sourceName,
int line,
int lineOffset)
Report a warning. |
List<String> |
warnings()
Returns the list of warnings, or null if there were none. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleErrorReporter()
| Method Detail |
|---|
public void warning(String message,
String sourceName,
int line,
int lineOffset)
ErrorReporter
warning in interface ErrorReportermessage - a String describing the warningsourceName - a String describing the JavaScript source
where the warning occurred; typically a filename or URLline - the line number associated with the warninglineOffset - the offset into lineSource where problem was detected
public void error(String message,
String sourceName,
int line,
int lineOffset)
ErrorReporter
error in interface ErrorReportermessage - a String describing the errorsourceName - a String describing the JavaScript source
where the error occurred; typically a filename or URLline - the line number associated with the errorlineOffset - the offset into lineSource where problem was detectedpublic List<String> errors()
null if there were none.
public List<String> warnings()
null if there were none.
public static String getMessage0(String messageId)
public static String getMessage1(String messageId,
Object arg1)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||