|
|
import org.apache.bsf.debug.*; | import org.apache.bsf.debug.*; |
import org.apache.bsf.debug.jsdi.*; | import org.apache.bsf.debug.jsdi.*; |
| |
public class RhinoEngineDebugger implements Debugger { |
class RhinoEngineDebugger implements Debugger { |
| |
/** The global script object, where all embedded functions are defined, | /** The global script object, where all embedded functions are defined, |
* as well as the standard ECMA "core" objects. | * as well as the standard ECMA "core" objects. |
*/ |
*/ |
private Scriptable global; | private Scriptable global; |
private JsObject globalstub; | private JsObject globalstub; |
| |
private RhinoContextProxy m_rcp; |
|
private Scriptable undefined; | private Scriptable undefined; |
private JsObject undefinedStub; | private JsObject undefinedStub; |
| |
/** |
/** |
* Hashtable allowing to find the stub for an object in the JavaScript | * Hashtable allowing to find the stub for an object in the JavaScript |
* environment if one exists. | * environment if one exists. |
* Typically: Scriptable, Function, Script, etc. | * Typically: Scriptable, Function, Script, etc. |
* This is not used for Context and DebugFrame. | * This is not used for Context and DebugFrame. |
* They typically contains JsObject associated to |
* They typically contains JsObject associated to |
* org.mozilla.javascript.ScriptableObject | * org.mozilla.javascript.ScriptableObject |
*/ | */ |
private Hashtable stubs; | private Hashtable stubs; |
|
|
private FnOrScript m_compilingFnOrScript; | private FnOrScript m_compilingFnOrScript; |
private JavaScriptEngine m_eng; | private JavaScriptEngine m_eng; |
| |
private Thread m_thread; |
|
|
|
private Hashtable m_documents; | private Hashtable m_documents; |
| |
BSFDebugManagerImpl dbgmgr; | BSFDebugManagerImpl dbgmgr; |
| |
public RhinoEngineDebugger(JavaScriptEngine eng) |
RhinoEngineDebugger(JavaScriptEngine eng) |
throws RemoteException { | throws RemoteException { |
super(); | super(); |
m_thread = Thread.currentThread(); |
|
m_eng = eng; | m_eng = eng; |
dbgmgr = eng.getDebugManager(); | dbgmgr = eng.getDebugManager(); |
| |
|
|
/** | /** |
* Called when our debugger has been disconnected. | * Called when our debugger has been disconnected. |
*/ | */ |
public void disconnectedDebuggerNotify() { |
void disconnectedDebuggerNotify() { |
m_callbacks = null; | m_callbacks = null; |
} | } |
| |
void addStub(Context cx, RhinoContextProxy jscx) { |
|
stubs.put(cx, jscx); |
|
} |
|
|
|
void addStub(DebugFrame frame, JsContextStub stub) { |
|
stubs.put(frame, stub); |
|
} |
|
|
|
void addStub(Scriptable sobj, JsObject jsobj) { | void addStub(Scriptable sobj, JsObject jsobj) { |
stubs.put(sobj, jsobj); | stubs.put(sobj, jsobj); |
} | } |
| |
void dropStub(Object key) { |
void dropStub(Scriptable key) { |
stubs.remove(key); | stubs.remove(key); |
} | } |
| |
public synchronized DocumentCell getDocumentCell(String name) { |
synchronized DocumentCell getDocumentCell(String name) { |
return (DocumentCell) m_documents.get(name); | return (DocumentCell) m_documents.get(name); |
} | } |
| |
// Called upon creation of a BSFManager. | // Called upon creation of a BSFManager. |
public synchronized DocumentCell loadDocumentNotify(String name) { |
synchronized DocumentCell loadDocumentNotify(String name) { |
DocumentCell cell; | DocumentCell cell; |
| |
cell = (DocumentCell) m_documents.get(name); | cell = (DocumentCell) m_documents.get(name); |
if (cell == null) { | if (cell == null) { |
cell = new DocumentCell(this, name); | cell = new DocumentCell(this, name); |
m_documents.put(name, cell); | m_documents.put(name, cell); |
if (dbgmgr!=null) |
if (dbgmgr!=null) |
dbgmgr.loadDocumentNotify(m_eng, name); | dbgmgr.loadDocumentNotify(m_eng, name); |
} | } |
return cell; | return cell; |
} | } |
| |
public synchronized void placeBreakpointAtLine(int brkptid, |
synchronized void placeBreakpointAtLine(int brkptid, |
String docname, | String docname, |
int lineno) { | int lineno) { |
| |
|
|
cell.addBreakpointAtLine(brkptid, lineno); | cell.addBreakpointAtLine(brkptid, lineno); |
} | } |
| |
public synchronized void placeBreakpointAtOffset(int brkptid, |
synchronized void placeBreakpointAtOffset(int brkptid, |
String docname, | String docname, |
int offset) { | int offset) { |
| |
|
|
cell.addBreakpointAtOffset(brkptid, offset); | cell.addBreakpointAtOffset(brkptid, offset); |
} | } |
| |
public void removeBreakpoint(String docname, int brkptid) |
void removeBreakpoint(String docname, int brkptid) |
throws BSFException { | throws BSFException { |
| |
DocumentCell cell; | DocumentCell cell; |
|
|
cell.removeBreakpoint(brkptid); | cell.removeBreakpoint(brkptid); |
} | } |
| |
public void setEntryExit(String docname, boolean on) |
void setEntryExit(String docname, boolean on) |
throws BSFException { | throws BSFException { |
| |
DocumentCell cell; | DocumentCell cell; |
|
|
cell.setEntryExit(on); | cell.setEntryExit(on); |
} | } |
| |
public Object eval(String docname, String fnOrScript, int lineno) |
Object eval(String docname, String fnOrScript, int lineno) |
throws RemoteException { | throws RemoteException { |
Object retval; | Object retval; |
try { | try { |
|
|
} | } |
} | } |
| |
public JsContext getContext(int depth) { |
JsContext getContext(int depth) { |
if (m_rcp != null) return m_rcp.getContext(depth); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
|
if (rcp != null) return rcp.getContextStub(depth); |
return null; | return null; |
} | } |
| |
public int getContextCount() { |
int getContextCount() { |
if (m_rcp != null) return m_rcp.getContextCount(); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
|
if (rcp != null) return rcp.getContextCount(); |
return -1; | return -1; |
} | } |
| |
|
|
* Return the current debugger. | * Return the current debugger. |
* @return the debugger, or null if none is attached. | * @return the debugger, or null if none is attached. |
*/ | */ |
public JsCallbacks getDebugger() { |
JsCallbacks getDebugger() { |
return m_callbacks; | return m_callbacks; |
} | } |
| |
public Object getDebugInterface() { |
Object getDebugInterface() { |
return engineStub; | return engineStub; |
} | } |
| |
public JsObject getGlobalObject() { |
JsObject getGlobalObject() { |
return globalstub; | return globalstub; |
} | } |
| |
public RhinoContextProxy getRhinoContextProxy() { |
|
return m_rcp; |
|
} |
|
|
|
RhinoContextProxy getStub(Context cx) { | RhinoContextProxy getStub(Context cx) { |
return (RhinoContextProxy) stubs.get(cx); |
return (RhinoContextProxy)cx.getDebuggerContextData(); |
} | } |
| |
JsContextStub getStub(DebugFrame frame) { | JsContextStub getStub(DebugFrame frame) { |
|
|
return (JsObject) stubs.get(sobj); | return (JsObject) stubs.get(sobj); |
} | } |
| |
public JsObject getUndefinedValue() { |
JsObject getUndefinedValue() { |
return undefinedStub; | return undefinedStub; |
} | } |
| |
public String getThread() { |
String getThread() { |
|
Context cx = Context.getCurrentContext(); |
String resultstr = ""; | String resultstr = ""; |
| |
if (m_thread != null) { |
if (cx != null) { |
try { | try { |
final String resultstrf = (String) | final String resultstrf = (String) |
AccessController.doPrivileged(new PrivilegedExceptionAction() { | AccessController.doPrivileged(new PrivilegedExceptionAction() { |
public Object run() throws Exception { | public Object run() throws Exception { |
return m_thread.getName(); |
return Thread.currentThread().getName(); |
} | } |
}); | }); |
resultstr = resultstrf; | resultstr = resultstrf; |
|
|
return resultstr; | return resultstr; |
} | } |
| |
public String getThreadGroup() { |
String getThreadGroup() { |
|
Context cx = Context.getCurrentContext(); |
String resultstr = ""; | String resultstr = ""; |
| |
if (m_thread != null) { |
if (cx != null) { |
try { | try { |
final String resultstrf = (String) | final String resultstrf = (String) |
AccessController.doPrivileged(new PrivilegedExceptionAction() { | AccessController.doPrivileged(new PrivilegedExceptionAction() { |
public Object run() throws Exception { | public Object run() throws Exception { |
return m_thread.getThreadGroup().getName(); |
return Thread.currentThread().getThreadGroup(). |
|
getName(); |
} | } |
}); | }); |
resultstr = resultstrf; | resultstr = resultstrf; |
|
|
// to implement STEP_IN, STEP_OUT, and STEP_OVER. | // to implement STEP_IN, STEP_OUT, and STEP_OVER. |
//--------------------------------------------------------- | //--------------------------------------------------------- |
| |
public void handleBreakpointHit(Context cx) { |
void handleBreakpointHit(Context cx, RhinoContextProxy rcp) { |
JsCallbacks debugger; | JsCallbacks debugger; |
BreakPoint bp; | BreakPoint bp; |
Enumeration e; | Enumeration e; |
|
|
boolean breakpointFound=false; | boolean breakpointFound=false; |
String name; | String name; |
int lineno; | int lineno; |
boolean suspend=false; |
|
|
DebugLog.stdoutPrintln("**** Handling a breakpoint hit...", |
m_thread = Thread.currentThread(); |
|
DebugLog.stdoutPrintln("**** Handling a breakpoint hit...", |
|
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_rcp = getStub(cx); |
// if we have no callbacks... then just |
if (m_rcp == null) { |
|
m_rcp = new RhinoContextProxy(this, cx); |
|
addStub(cx, m_rcp); |
|
} |
|
// if we have no callbacks... then just |
|
// ignore the breakpoint hit, do a run | // ignore the breakpoint hit, do a run |
// so that execution resumes... | // so that execution resumes... |
if (m_callbacks==null) { | if (m_callbacks==null) { |
DebugLog.stdoutPrintln(" No callbacks, resuming...", DebugLog.BSF_LOG_L3); |
DebugLog.stdoutPrintln(" No callbacks, resuming...", DebugLog.BSF_LOG_L3); |
m_rcp.run(); |
rcp.run(); |
| |
} else { | } else { |
// First, check that we didn't hit a known breakpoint. | // First, check that we didn't hit a known breakpoint. |
// First, search if we have breakpoints for the current documents | // First, search if we have breakpoints for the current documents |
| |
name = m_rcp.getSourceName(); |
name = rcp.getSourceName(); |
lineno = m_rcp.getLineNumber(); |
lineno = rcp.getLineNumber(); |
| |
DebugLog.stdoutPrintln(" in "+name+" at "+lineno, DebugLog.BSF_LOG_L3); |
DebugLog.stdoutPrintln(" in "+name+" at "+lineno, DebugLog.BSF_LOG_L3); |
| |
cell = getDocumentCell(name); | cell = getDocumentCell(name); |
if (cell != null) |
if (cell != null) |
_handleBreakpointHit(cell,lineno); |
_handleBreakpointHit(rcp,cell,lineno); |
} |
} |
m_rcp = null; |
|
} | } |
| |
public void _handleBreakpointHit(DocumentCell cell, int lineno) { |
void _handleBreakpointHit(RhinoContextProxy rcp, |
|
DocumentCell cell, int lineno) |
|
{ |
JsCallbacks debugger; | JsCallbacks debugger; |
BreakPoint bp; | BreakPoint bp; |
Enumeration e; | Enumeration e; |
JsContext stub=null; | JsContext stub=null; |
boolean breakpointFound=false; | boolean breakpointFound=false; |
boolean suspend=false; | boolean suspend=false; |
|
|
try { | try { |
bp = cell.findBreakpointAtLine(lineno); | bp = cell.findBreakpointAtLine(lineno); |
} catch (BSFException bsfex) { | } catch (BSFException bsfex) { |
|
|
if (bp != null) { | if (bp != null) { |
breakpointFound = true; | breakpointFound = true; |
try { | try { |
stub = m_rcp.hitBreakpoint(); |
stub = rcp.hitBreakpoint(); |
DebugLog.stdoutPrintln(" breakpoint callback...", DebugLog.BSF_LOG_L3); |
DebugLog.stdoutPrintln(" breakpoint callback...", DebugLog.BSF_LOG_L3); |
m_callbacks.createFuture(m_rcp); |
m_callbacks.createFuture(rcp); |
m_callbacks.handleBreakpointHit(stub); | m_callbacks.handleBreakpointHit(stub); |
suspend = true; | suspend = true; |
} catch (RemoteException rex) { | } catch (RemoteException rex) { |
DebugLog.stderrPrintln(" EXCEPTION OCCURED DURING BREAKPOINT CALLBACK", DebugLog.BSF_LOG_L0); |
DebugLog.stderrPrintln(" EXCEPTION OCCURED DURING BREAKPOINT CALLBACK", DebugLog.BSF_LOG_L0); |
DebugLog.stderrPrintln(rex.getMessage(), DebugLog.BSF_LOG_L0); | DebugLog.stderrPrintln(rex.getMessage(), DebugLog.BSF_LOG_L0); |
rex.printStackTrace(); | rex.printStackTrace(); |
suspend = false; | suspend = false; |
} | } |
} else { | } else { |
DebugLog.stdoutPrintln(" didn't find a breakpoint...", DebugLog.BSF_LOG_L3); |
DebugLog.stdoutPrintln(" didn't find a breakpoint...", DebugLog.BSF_LOG_L3); |
breakpointFound = false; | breakpointFound = false; |
} | } |
| |
|
|
// line in the current document, we must be stepping | // line in the current document, we must be stepping |
// or in entry/exit mode | // or in entry/exit mode |
try { | try { |
stub = m_rcp.stepping(); |
stub = rcp.stepping(); |
FnOrScript current = cell.findFnOrScriptContaining(lineno); | FnOrScript current = cell.findFnOrScriptContaining(lineno); |
if (stub != null) { | if (stub != null) { |
cell.setLastFnOrScript(current); | cell.setLastFnOrScript(current); |
DebugLog.stdoutPrintln(" stepping-done callback...", |
DebugLog.stdoutPrintln(" stepping-done callback...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_callbacks.createFuture(m_rcp); |
m_callbacks.createFuture(rcp); |
m_callbacks.handleSteppingDone(stub); | m_callbacks.handleSteppingDone(stub); |
suspend = true; | suspend = true; |
} |
} |
else if (cell.getEntryExit() && | else if (cell.getEntryExit() && |
(current != cell.getLastFnOrScript()) && | (current != cell.getLastFnOrScript()) && |
(m_rcp.getContextCount() == 0)) { |
(rcp.getContextCount() == 0)) { |
cell.setLastFnOrScript(current); | cell.setLastFnOrScript(current); |
stub = m_rcp.entry_exit_mode(); |
stub = rcp.entry_exit_mode(); |
DebugLog.stdoutPrintln(" entry/exit mode...", |
DebugLog.stdoutPrintln(" entry/exit mode...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_callbacks.createFuture(m_rcp); |
m_callbacks.createFuture(rcp); |
m_callbacks.handleSteppingDone(stub); | m_callbacks.handleSteppingDone(stub); |
suspend = true; | suspend = true; |
} | } |
else { | else { |
DebugLog.stdoutPrintln(" No reason to suspend execution.", DebugLog.BSF_LOG_L3); |
DebugLog.stdoutPrintln(" No reason to suspend execution.", DebugLog.BSF_LOG_L3); |
suspend = false; | suspend = false; |
} | } |
} catch (RemoteException rex) { | } catch (RemoteException rex) { |
DebugLog.stderrPrintln(" EXCEPTION OCCURED DURING STEPPING-DONE CALLBACK", DebugLog.BSF_LOG_L0); |
DebugLog.stderrPrintln(" EXCEPTION OCCURED DURING STEPPING-DONE CALLBACK", DebugLog.BSF_LOG_L0); |
DebugLog.stderrPrintln(rex.getMessage(), DebugLog.BSF_LOG_L0); | DebugLog.stderrPrintln(rex.getMessage(), DebugLog.BSF_LOG_L0); |
rex.printStackTrace(); | rex.printStackTrace(); |
suspend = false; | suspend = false; |
} | } |
} | } |
if (suspend) { | if (suspend) { |
// now, suspend this thread... until |
// now, suspend this thread... until |
// we restart. | // we restart. |
try { | try { |
m_callbacks.suspendFuture(m_rcp); |
m_callbacks.suspendFuture(rcp); |
} catch (Exception ex) { | } catch (Exception ex) { |
DebugLog.stdoutPrintln("Future creation failed... releasing the engine", DebugLog.BSF_LOG_L3); | DebugLog.stdoutPrintln("Future creation failed... releasing the engine", DebugLog.BSF_LOG_L3); |
m_rcp.run(); |
rcp.run(); |
} | } |
} |
} |
} | } |
| |
public void run(JsEngineStub eng) throws Exception { |
void run(JsEngineStub eng) throws Exception { |
DebugLog.stdoutPrintln("RhinoEngineDebugger::run()...", | DebugLog.stdoutPrintln("RhinoEngineDebugger::run()...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_rcp.run(); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
m_callbacks.completeFuture(m_rcp); |
rcp.run(); |
|
m_callbacks.completeFuture(rcp); |
} | } |
| |
public void stepIn(JsEngineStub eng) throws Exception { |
void stepIn(JsEngineStub eng) throws Exception { |
DebugLog.stdoutPrintln("RhinoEngineDebugger::stepIn()...", | DebugLog.stdoutPrintln("RhinoEngineDebugger::stepIn()...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_rcp.stepIn(); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
m_callbacks.completeFuture(m_rcp); |
rcp.stepIn(); |
|
m_callbacks.completeFuture(rcp); |
} | } |
| |
public void stepOut(JsEngineStub eng) throws Exception { |
void stepOut(JsEngineStub eng) throws Exception { |
DebugLog.stdoutPrintln("RhinoEngineDebugger::stepOut()...", | DebugLog.stdoutPrintln("RhinoEngineDebugger::stepOut()...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_rcp.stepOut(); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
m_callbacks.completeFuture(m_rcp); |
rcp.stepOut(); |
|
m_callbacks.completeFuture(rcp); |
} | } |
public void stepOver(JsEngineStub eng) throws Exception { |
void stepOver(JsEngineStub eng) throws Exception { |
| |
DebugLog.stdoutPrintln("RhinoEngineDebugger::stepOver()...", | DebugLog.stdoutPrintln("RhinoEngineDebugger::stepOver()...", |
DebugLog.BSF_LOG_L3); | DebugLog.BSF_LOG_L3); |
m_rcp.stepOver(); |
RhinoContextProxy rcp = RhinoContextProxy.getCurrent(); |
m_callbacks.completeFuture(m_rcp); |
rcp.stepOver(); |
|
m_callbacks.completeFuture(rcp); |
} | } |
|
|
public void handleCompilationDone(Context cx, | public void handleCompilationDone(Context cx, |
DebuggableScript fnOrScript, | DebuggableScript fnOrScript, |
StringBuffer source) { |
String source) { |
| |
m_thread = Thread.currentThread(); |
|
m_compilingFnOrScript.addCompilationUnit(cx, fnOrScript, source); | m_compilingFnOrScript.addCompilationUnit(cx, fnOrScript, source); |
} | } |
| |
public void handleExceptionThrown(Context cx, Object exceptionThrown) { |
public DebugFrame getFrame(Context cx, DebuggableScript fnOrScript) { |
|
CompilationUnit unit; |
|
unit = m_compilingFnOrScript.getCompilationUnit(fnOrScript); |
|
RhinoContextProxy rcp = getStub(cx); |
|
try { |
|
JsContextStub stub = new JsContextStub(rcp, unit); |
|
return stub.getRhinoDebugFrame(); |
|
} catch (RemoteException rex) { |
|
DebugLog.stderrPrintln(" EXCEPTION OCCURED DURING FRAME INITIALIZATION", DebugLog.BSF_LOG_L0); |
|
DebugLog.stderrPrintln(rex.getMessage(), DebugLog.BSF_LOG_L0); |
|
rex.printStackTrace(); |
|
return null; |
|
} |
|
} |
|
|
|
void handleExceptionThrown(Context cx, RhinoContextProxy rcp, |
|
Throwable exceptionThrown) |
|
{ |
JsContext stub; | JsContext stub; |
JsCallbacks debugger; | JsCallbacks debugger; |
BreakPoint bp; | BreakPoint bp; |
|
|
String name,msg; | String name,msg; |
Exception ex; | Exception ex; |
int lineno; | int lineno; |
NativeError error; |
|
|
// if we have no callbacks... then just |
m_thread = Thread.currentThread(); |
// ignore the breakpoint hit, do a run |
m_rcp = getStub(cx); |
// so that execution resumes... |
if (m_rcp == null) { |
if (m_callbacks==null) { |
m_rcp = new RhinoContextProxy(this, cx); |
rcp.run(); |
addStub(cx, m_rcp); |
return; |
} | } |
try { |
|
// if we have no callbacks... then just |
|
// ignore the breakpoint hit, do a run |
|
// so that execution resumes... |
|
if (m_callbacks==null) { |
|
m_rcp.run(); |
|
return; |
|
} |
|
| |
// First, check that we didn't hit a known breakpoint. |
// First, check that we didn't hit a known breakpoint. |
// First, search if we have breakpoints for the current documents |
// First, search if we have breakpoints for the current documents |
name = m_rcp.getSourceName(); |
name = rcp.getSourceName(); |
lineno = m_rcp.getLineNumber(); |
lineno = rcp.getLineNumber(); |
try { |
if (exceptionThrown instanceof EcmaError) { |
error = (NativeError)exceptionThrown; |
msg = ((EcmaError)exceptionThrown).getErrorObject().toString(); |
msg = error.getName() + ": " + error.getMessage(); |
} else { |
} catch (ClassCastException ccex) { |
msg = exceptionThrown.toString(); |
msg = "Unknown JavaScript Exception"; |
} |
} |
ex = new Exception(msg); |
ex = new Exception(msg); |
|
| |
cell = getDocumentCell(name); |
cell = getDocumentCell(name); |
if (cell == null) return; |
if (cell == null) return; |
| |
try { |
try { |
stub = m_rcp.exceptionThrown(); |
stub = rcp.exceptionThrown(); |
m_callbacks.createFuture(m_rcp); |
m_callbacks.createFuture(rcp); |
m_callbacks.handleExceptionThrown(stub,ex); |
m_callbacks.handleExceptionThrown(stub,ex); |
|
|
// now, suspend this thread... until |
// now, suspend this thread... until |
// we restart. |
// we restart. |
m_callbacks.suspendFuture(m_rcp); |
m_callbacks.suspendFuture(rcp); |
|
|
} catch (Exception ex2) { |
} catch (Exception ex2) { |
m_rcp.run(); |
rcp.run(); |
|
|
} |
|
} finally { |
|
m_rcp = null; |
|
} | } |
} | } |
| |
|
|
* The engine will call the attached debugger's handleBreakpointHit | * The engine will call the attached debugger's handleBreakpointHit |
* method on the next line it executes if isLineStep is true. | * method on the next line it executes if isLineStep is true. |
* May be used from another thread to interrupt execution. | * May be used from another thread to interrupt execution. |
* |
* |
* @param isLineStep if true, break next line | * @param isLineStep if true, break next line |
*/ | */ |
public void setBreakNextLine(JsContext context, boolean isLineStep) { |
void setBreakNextLine(JsContext context, boolean isLineStep) { |
} | } |
| |
void setCompilingFnOrScript(FnOrScript fnOrScript) { | void setCompilingFnOrScript(FnOrScript fnOrScript) { |
|
|
* @param debugger the debugger to be used on callbacks from | * @param debugger the debugger to be used on callbacks from |
* the engine. | * the engine. |
*/ | */ |
public void setDebugger(JsCallbacks debugger) { |
void setDebugger(JsCallbacks debugger) { |
m_callbacks = debugger; | m_callbacks = debugger; |
} | } |
} | } |