Class Main
- java.lang.Object
- 
- org.mozilla.javascript.tools.debugger.Main
 
- 
 public class Main extends java.lang.Object
- 
- 
Constructor SummaryConstructors Constructor Description Main(java.lang.String title)Creates a new Main.
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description voidattachTo(ContextFactory factory)Attaches the debugger to the givenContextFactory.voidclearAllBreakpoints()Removes all breakpoints.voidcontextCreated(Context cx)Deprecated.The method is only present for compatibility and should not be called.voidcontextEntered(Context cx)Deprecated.The method is only present for compatibility and should not be called.voidcontextExited(Context cx)Deprecated.The method is only present for compatibility and should not be called.voidcontextReleased(Context cx)Deprecated.The method is only present for compatibility and should not be called.voiddetach()Detaches from the currentContextFactory.voiddispose()Frees any resources held by the debugger.voiddoBreak()Breaks execution of the script.javax.swing.JFramegetDebugFrame()Returns the debugger windowJFrame.java.io.PrintStreamgetErr()Returns aPrintStreamfor stderr in the Debugger's internal Console window.java.io.InputStreamgetIn()Returns anInputStreamfor stdin from the debugger's internal Console window.java.io.PrintStreamgetOut()Returns aPrintStreamfor stdout to the debugger's internal Console window.voidgo()Resumes execution of the script.booleanisVisible()Returns whether the debugger GUI frame is visible.static voidmain(java.lang.String[] args)Main entry point.static MainmainEmbedded(java.lang.String title)Entry point for embedded applications.static MainmainEmbedded(ContextFactory factory, Scriptable scope, java.lang.String title)Entry point for embedded applications.static MainmainEmbedded(ContextFactory factory, ScopeProvider scopeProvider, java.lang.String title)Entry point for embedded applications.voidpack()Packs the debugger GUI frame.voidsetBreakOnEnter(boolean value)Sets whether execution should break when a function is entered.voidsetBreakOnExceptions(boolean value)Sets whether execution should break when a script exception is thrown.voidsetBreakOnReturn(boolean value)Sets whether execution should break when a function is left.voidsetExitAction(java.lang.Runnable r)Assign a Runnable object that will be invoked when the user selects "Exit..." or closes the Debugger main window.voidsetOptimizationLevel(int level)Deprecated.The method does nothing and is only present for compatibility.voidsetScope(Scriptable scope)Sets the scope to be used for script evaluation.voidsetScopeProvider(ScopeProvider p)Sets theScopeProviderthat provides a scope to be used for script evaluation.voidsetSize(int w, int h)Sets the debugger GUI frame dimensions.voidsetSize(java.awt.Dimension dimension)Deprecated.UsesetSize(int, int)instead.voidsetSourceProvider(SourceProvider sourceProvider)Sets theSourceProviderthat provides the source to be displayed for script evaluation.voidsetVisible(boolean flag)Sets the visibility of the debugger GUI frame.
 
- 
- 
- 
Method Detail- 
getDebugFramepublic javax.swing.JFrame getDebugFrame() Returns the debugger windowJFrame.
 - 
doBreakpublic void doBreak() Breaks execution of the script.
 - 
setBreakOnExceptionspublic void setBreakOnExceptions(boolean value) Sets whether execution should break when a script exception is thrown.
 - 
setBreakOnEnterpublic void setBreakOnEnter(boolean value) Sets whether execution should break when a function is entered.
 - 
setBreakOnReturnpublic void setBreakOnReturn(boolean value) Sets whether execution should break when a function is left.
 - 
clearAllBreakpointspublic void clearAllBreakpoints() Removes all breakpoints.
 - 
gopublic void go() Resumes execution of the script.
 - 
setScopepublic void setScope(Scriptable scope) Sets the scope to be used for script evaluation.
 - 
setScopeProviderpublic void setScopeProvider(ScopeProvider p) Sets theScopeProviderthat provides a scope to be used for script evaluation.
 - 
setSourceProviderpublic void setSourceProvider(SourceProvider sourceProvider) Sets theSourceProviderthat provides the source to be displayed for script evaluation.
 - 
setExitActionpublic void setExitAction(java.lang.Runnable r) Assign a Runnable object that will be invoked when the user selects "Exit..." or closes the Debugger main window.
 - 
getInpublic java.io.InputStream getIn() Returns anInputStreamfor stdin from the debugger's internal Console window.
 - 
getOutpublic java.io.PrintStream getOut() Returns aPrintStreamfor stdout to the debugger's internal Console window.
 - 
getErrpublic java.io.PrintStream getErr() Returns aPrintStreamfor stderr in the Debugger's internal Console window.
 - 
packpublic void pack() Packs the debugger GUI frame.
 - 
setSizepublic void setSize(int w, int h)Sets the debugger GUI frame dimensions.
 - 
setVisiblepublic void setVisible(boolean flag) Sets the visibility of the debugger GUI frame.
 - 
isVisiblepublic boolean isVisible() Returns whether the debugger GUI frame is visible.
 - 
disposepublic void dispose() Frees any resources held by the debugger.
 - 
attachTopublic void attachTo(ContextFactory factory) Attaches the debugger to the givenContextFactory.
 - 
detachpublic void detach() Detaches from the currentContextFactory.
 - 
mainpublic static void main(java.lang.String[] args) Main entry point. Creates a debugger attached to a RhinoMainshell session.
 - 
mainEmbeddedpublic static Main mainEmbedded(java.lang.String title) Entry point for embedded applications. This method attaches to the globalContextFactorywith a scope of a newly createdGlobalobject. No I/O redirection is performed as withmain(String[]).
 - 
mainEmbeddedpublic static Main mainEmbedded(ContextFactory factory, Scriptable scope, java.lang.String title) Entry point for embedded applications. This method attaches to the givenContextFactorywith the given scope. No I/O redirection is performed as withmain(String[]).
 - 
mainEmbeddedpublic static Main mainEmbedded(ContextFactory factory, ScopeProvider scopeProvider, java.lang.String title) Entry point for embedded applications. This method attaches to the givenContextFactorywith the given scope. No I/O redirection is performed as withmain(String[]).
 - 
setSize@Deprecated public void setSize(java.awt.Dimension dimension) Deprecated.UsesetSize(int, int)instead.
 - 
setOptimizationLevel@Deprecated public void setOptimizationLevel(int level) Deprecated.The method does nothing and is only present for compatibility.
 - 
contextEntered@Deprecated public void contextEntered(Context cx) Deprecated.The method is only present for compatibility and should not be called.
 - 
contextExited@Deprecated public void contextExited(Context cx) Deprecated.The method is only present for compatibility and should not be called.
 - 
contextCreated@Deprecated public void contextCreated(Context cx) Deprecated.The method is only present for compatibility and should not be called.
 - 
contextReleased@Deprecated public void contextReleased(Context cx) Deprecated.The method is only present for compatibility and should not be called.
 
- 
 
-