Class Dim
- java.lang.Object
- 
- org.mozilla.javascript.tools.debugger.Dim
 
- 
 public class Dim extends java.lang.ObjectDim or Debugger Implementation for Rhino.
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description static classDim.ContextDataClass to store information about a stack.static classDim.FunctionSourceClass to store information about a function.static classDim.SourceInfoClass to store information about a script source.static classDim.StackFrameObject to represent one stack frame.
 - 
Constructor SummaryConstructors Constructor Description Dim()
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidattachTo(ContextFactory factory)Attaches the debugger to the given ContextFactory.voidclearAllBreakpoints()Clears all breakpoints.voidcompileScript(java.lang.String url, java.lang.String text)Compiles the given script.voidcontextSwitch(int frameIndex)Switches context to the stack frame with the given index.Dim.ContextDatacurrentContextData()Returns the current ContextData object.voiddetach()Detaches the debugger from the current ContextFactory.voiddispose()Releases resources associated with this debugger.java.lang.Stringeval(java.lang.String expr)Evaluates the given script.voidevalScript(java.lang.String url, java.lang.String text)Evaluates the given script.java.lang.String[]functionNames()Returns an array of all function names.Dim.FunctionSourcefunctionSourceByName(java.lang.String functionName)Returns the FunctionSource object for the function with the given name.java.lang.Object[]getObjectIds(java.lang.Object object)Returns an array of the property names on the given script object.java.lang.ObjectgetObjectProperty(java.lang.Object object, java.lang.Object id)Returns the value of a property on the given script object.voidgo()Resumes execution of script.java.lang.StringobjectToString(java.lang.Object object)Converts the given script object to a string.voidsetBreak()Tells the debugger to break at the next opportunity.voidsetBreakOnEnter(boolean breakOnEnter)Sets whether the debugger should break on function entering.voidsetBreakOnExceptions(boolean breakOnExceptions)Sets whether the debugger should break on exceptions.voidsetBreakOnReturn(boolean breakOnReturn)Sets whether the debugger should break on function return.voidsetGuiCallback(GuiCallback callback)Sets the GuiCallback object to use.voidsetReturnValue(int returnValue)Sets the action to perform to end interruption.voidsetScopeProvider(ScopeProvider scopeProvider)Sets the ScopeProvider to be used.voidsetSourceProvider(SourceProvider sourceProvider)Sets the ScopeProvider to be used.Dim.SourceInfosourceInfo(java.lang.String url)Returns the SourceInfo object for the given URL.booleanstringIsCompilableUnit(java.lang.String str)Returns whether the given string is syntactically valid script.
 
- 
- 
- 
Field Detail- 
STEP_OVERpublic static final int STEP_OVER - See Also:
- Constant Field Values
 
 - 
STEP_INTOpublic static final int STEP_INTO - See Also:
- Constant Field Values
 
 - 
STEP_OUTpublic static final int STEP_OUT - See Also:
- Constant Field Values
 
 - 
GOpublic static final int GO - See Also:
- Constant Field Values
 
 - 
BREAKpublic static final int BREAK - See Also:
- Constant Field Values
 
 - 
EXITpublic static final int EXIT - See Also:
- Constant Field Values
 
 
- 
 - 
Method Detail- 
setGuiCallbackpublic void setGuiCallback(GuiCallback callback) Sets the GuiCallback object to use.
 - 
setBreakpublic void setBreak() Tells the debugger to break at the next opportunity.
 - 
setScopeProviderpublic void setScopeProvider(ScopeProvider scopeProvider) Sets the ScopeProvider to be used.
 - 
setSourceProviderpublic void setSourceProvider(SourceProvider sourceProvider) Sets the ScopeProvider to be used.
 - 
contextSwitchpublic void contextSwitch(int frameIndex) Switches context to the stack frame with the given index.
 - 
setBreakOnExceptionspublic void setBreakOnExceptions(boolean breakOnExceptions) Sets whether the debugger should break on exceptions.
 - 
setBreakOnEnterpublic void setBreakOnEnter(boolean breakOnEnter) Sets whether the debugger should break on function entering.
 - 
setBreakOnReturnpublic void setBreakOnReturn(boolean breakOnReturn) Sets whether the debugger should break on function return.
 - 
attachTopublic void attachTo(ContextFactory factory) Attaches the debugger to the given ContextFactory.
 - 
detachpublic void detach() Detaches the debugger from the current ContextFactory.
 - 
disposepublic void dispose() Releases resources associated with this debugger.
 - 
functionNamespublic java.lang.String[] functionNames() Returns an array of all function names.
 - 
functionSourceByNamepublic Dim.FunctionSource functionSourceByName(java.lang.String functionName) Returns the FunctionSource object for the function with the given name.
 - 
sourceInfopublic Dim.SourceInfo sourceInfo(java.lang.String url) Returns the SourceInfo object for the given URL.
 - 
clearAllBreakpointspublic void clearAllBreakpoints() Clears all breakpoints.
 - 
currentContextDatapublic Dim.ContextData currentContextData() Returns the current ContextData object.
 - 
setReturnValuepublic void setReturnValue(int returnValue) Sets the action to perform to end interruption.
 - 
gopublic void go() Resumes execution of script.
 - 
evalpublic java.lang.String eval(java.lang.String expr) Evaluates the given script.
 - 
compileScriptpublic void compileScript(java.lang.String url, java.lang.String text)Compiles the given script.
 - 
evalScriptpublic void evalScript(java.lang.String url, java.lang.String text)Evaluates the given script.
 - 
objectToStringpublic java.lang.String objectToString(java.lang.Object object) Converts the given script object to a string.
 - 
stringIsCompilableUnitpublic boolean stringIsCompilableUnit(java.lang.String str) Returns whether the given string is syntactically valid script.
 - 
getObjectPropertypublic java.lang.Object getObjectProperty(java.lang.Object object, java.lang.Object id)Returns the value of a property on the given script object.
 - 
getObjectIdspublic java.lang.Object[] getObjectIds(java.lang.Object object) Returns an array of the property names on the given script object.
 
- 
 
-