Class Dim.StackFrame
java.lang.Object
org.mozilla.javascript.tools.debugger.Dim.StackFrame
- All Implemented Interfaces:
DebugFrame
- Enclosing class:
Dim
Object to represent one stack frame.
-
Method Summary
Modifier and TypeMethodDescriptionReturns the ContextData object for the Context.Returns the current function name.int
Returns the current line number.getUrl()
Returns the source URL.void
Called when a 'debugger' statement is executed.void
onEnter
(Context cx, Scriptable scope, Scriptable thisObj, Object[] args) Called when the stack frame is entered.void
onExceptionThrown
(Context cx, Throwable exception) Called when an exception has been thrown.void
Called when the stack frame has been left.void
onLineChange
(Context cx, int lineno) Called when the current position has changed.scope()
Returns the scope object for this frame.Returns the SourceInfo object for the function.thisObj()
Returns the 'this' object for this frame.
-
Method Details
-
onEnter
Called when the stack frame is entered.- Specified by:
onEnter
in interfaceDebugFrame
- Parameters:
cx
- current Context for this threadscope
- the activation scope for the function or script.thisObj
- value of the JavaScriptthis
objectargs
- the array of arguments
-
onLineChange
Called when the current position has changed.- Specified by:
onLineChange
in interfaceDebugFrame
- Parameters:
cx
- current Context for this threadlineno
- current line number in the script source
-
onExceptionThrown
Called when an exception has been thrown.- Specified by:
onExceptionThrown
in interfaceDebugFrame
- Parameters:
cx
- current Context for this threadexception
- exception object
-
onExit
Called when the stack frame has been left.- Specified by:
onExit
in interfaceDebugFrame
- Parameters:
cx
- current Context for this threadbyThrow
- if true function will leave by throwing exception, otherwise it will execute normal returnresultOrException
- function result in case of normal return or exception object if about to throw exception
-
onDebuggerStatement
Called when a 'debugger' statement is executed.- Specified by:
onDebuggerStatement
in interfaceDebugFrame
- Parameters:
cx
- current Context for this thread
-
sourceInfo
Returns the SourceInfo object for the function. -
contextData
Returns the ContextData object for the Context. -
scope
Returns the scope object for this frame. -
thisObj
Returns the 'this' object for this frame. -
getUrl
Returns the source URL. -
getLineNumber
public int getLineNumber()Returns the current line number. -
getFunctionName
Returns the current function name.
-