Package org.htmlunit.javascript
Class HtmlUnitContextFactory.HtmlUnitErrorReporter
java.lang.Object
org.htmlunit.javascript.HtmlUnitContextFactory.HtmlUnitErrorReporter
- All Implemented Interfaces:
Serializable,org.htmlunit.corejs.javascript.ErrorReporter
- Enclosing class:
HtmlUnitContextFactory
private static final class HtmlUnitContextFactory.HtmlUnitErrorReporter
extends Object
implements org.htmlunit.corejs.javascript.ErrorReporter, Serializable
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionHtmlUnitErrorReporter(JavaScriptErrorListener javaScriptErrorListener) Ctor. -
Method Summary
Modifier and TypeMethodDescriptionvoidLogs an error.org.htmlunit.corejs.javascript.EvaluatorExceptionruntimeError(String message, String sourceName, int line, String lineSource, int lineOffset) Logs a runtime error.voidLogs a warning.
-
Field Details
-
javaScriptErrorListener_
-
-
Constructor Details
-
HtmlUnitErrorReporter
HtmlUnitErrorReporter(JavaScriptErrorListener javaScriptErrorListener) Ctor.- Parameters:
javaScriptErrorListener- the listener to be used
-
-
Method Details
-
warning
Logs a warning.- Specified by:
warningin interfaceorg.htmlunit.corejs.javascript.ErrorReporter- Parameters:
message- the message to be displayedsourceName- the name of the source fileline- the line numberlineSource- the source code that failedlineOffset- the line offset
-
error
Logs an error.- Specified by:
errorin interfaceorg.htmlunit.corejs.javascript.ErrorReporter- Parameters:
message- the message to be displayedsourceName- the name of the source fileline- the line numberlineSource- the source code that failedlineOffset- the line offset
-
runtimeError
public org.htmlunit.corejs.javascript.EvaluatorException runtimeError(String message, String sourceName, int line, String lineSource, int lineOffset) Logs a runtime error.- Specified by:
runtimeErrorin interfaceorg.htmlunit.corejs.javascript.ErrorReporter- Parameters:
message- the message to be displayedsourceName- the name of the source fileline- the line numberlineSource- the source code that failedlineOffset- the line offset- Returns:
- an evaluator exception
-