com.gargoylesoftware.htmlunit.javascript
Class DebugFrameImpl

java.lang.Object
  extended by com.gargoylesoftware.htmlunit.javascript.DebugFrameImpl
All Implemented Interfaces:
org.mozilla.javascript.debug.DebugFrame

public class DebugFrameImpl
extends java.lang.Object
implements org.mozilla.javascript.debug.DebugFrame

HtmlUnit's implementation of the DebugFrame interface, which logs stack entries as well as exceptions. All logging is done at the TRACE level. This class does a fairly good job of guessing names for anonymous functions when they are referenced by name from an existing object. See the Rhino documentation or the interface source code for more information on the DebugFrame interface and its uses.

Please note that this class is intended mainly to aid in the debugging and development of HtmlUnit itself, rather than the debugging and development of web applications.

Version:
$Revision: 1.3 $
Author:
Daniel Gredler
See Also:
DebuggerImpl

Constructor Summary
DebugFrameImpl(org.mozilla.javascript.debug.DebuggableScript functionOrScript)
 Creates a new debug frame.
 
Method Summary
 void onEnter(org.mozilla.javascript.Context cx, org.mozilla.javascript.Scriptable activation, org.mozilla.javascript.Scriptable thisObj, java.lang.Object[] args)
 
 void onExceptionThrown(org.mozilla.javascript.Context cx, java.lang.Throwable t)
 
 void onExit(org.mozilla.javascript.Context cx, boolean byThrow, java.lang.Object resultOrException)
 
 void onLineChange(org.mozilla.javascript.Context cx, int lineNumber)
 
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mozilla.javascript.debug.DebugFrame
onDebuggerStatement
 

Constructor Detail

DebugFrameImpl

public DebugFrameImpl(org.mozilla.javascript.debug.DebuggableScript functionOrScript)
Creates a new debug frame.

Parameters:
functionOrScript - the function or script to which this frame corresponds
Method Detail

onEnter

public void onEnter(org.mozilla.javascript.Context cx,
                    org.mozilla.javascript.Scriptable activation,
                    org.mozilla.javascript.Scriptable thisObj,
                    java.lang.Object[] args)

Specified by:
onEnter in interface org.mozilla.javascript.debug.DebugFrame

onExceptionThrown

public void onExceptionThrown(org.mozilla.javascript.Context cx,
                              java.lang.Throwable t)

Specified by:
onExceptionThrown in interface org.mozilla.javascript.debug.DebugFrame

onExit

public void onExit(org.mozilla.javascript.Context cx,
                   boolean byThrow,
                   java.lang.Object resultOrException)

Specified by:
onExit in interface org.mozilla.javascript.debug.DebugFrame

onLineChange

public void onLineChange(org.mozilla.javascript.Context cx,
                         int lineNumber)

Specified by:
onLineChange in interface org.mozilla.javascript.debug.DebugFrame


Copyright © 2003-2016 AppPerfect Corporation. All Rights Reserved.