public class SilentJavaScriptErrorListener extends Object implements JavaScriptErrorListener, Serializable
JavaScriptErrorListener
that does no logging at all.Constructor and Description |
---|
SilentJavaScriptErrorListener() |
Modifier and Type | Method and Description |
---|---|
void |
loadScriptError(HtmlPage page,
URL scriptUrl,
Exception exception)
Informs about an exception during load of a javascript file refereed from a page.
|
void |
malformedScriptURL(HtmlPage page,
String url,
MalformedURLException malformedURLException)
Informs about a malformed url referencing to to script.
|
void |
scriptException(HtmlPage page,
ScriptException scriptException)
Informs about a javascript exceptions.
|
void |
timeoutError(HtmlPage page,
long allowedTime,
long executionTime)
Informs about a javascript timeout error.
|
void |
warn(String message,
String sourceName,
int line,
String lineSource,
int lineOffset)
Informs about a javascript warning.
|
public void scriptException(HtmlPage page, ScriptException scriptException)
JavaScriptErrorListener
scriptException
in interface JavaScriptErrorListener
page
- the page that causes the problemscriptException
- the occurred script exceptionpublic void timeoutError(HtmlPage page, long allowedTime, long executionTime)
JavaScriptErrorListener
timeoutError
in interface JavaScriptErrorListener
page
- the page that causes the problemallowedTime
- the max time allowed for the executionexecutionTime
- the already consumed timepublic void malformedScriptURL(HtmlPage page, String url, MalformedURLException malformedURLException)
JavaScriptErrorListener
malformedScriptURL
in interface JavaScriptErrorListener
page
- the page that causes the problemurl
- the malformed urlmalformedURLException
- the occurred exceptionpublic void loadScriptError(HtmlPage page, URL scriptUrl, Exception exception)
JavaScriptErrorListener
loadScriptError
in interface JavaScriptErrorListener
page
- the page that causes the problemscriptUrl
- the url to load the script fromexception
- the occurred exceptionpublic void warn(String message, String sourceName, int line, String lineSource, int lineOffset)
JavaScriptErrorListener
warn
in interface JavaScriptErrorListener
message
- the message to be displayedsourceName
- the name of the source fileline
- the line numberlineSource
- the source code that failedlineOffset
- the line offsetCopyright © 2002–2024 Gargoyle Software Inc.. All rights reserved.