AssemblyLine Debugger
The AssemblyLine debugger is a very simple debugger that allows you to
suspend AssemblyLine processing and show values of various variables and
objects in a debugger console. You must open the debugger console in the admin
tool (under View|Debugger) and click the Start button. This will cause the debugger console to
start listening for incoming TCP connections. An incoming TCP connection is
established when the task.enableDebug call is used within an AssemblyLine.
The debug process is managed by four calls in
the AssemblyLine:
- task.enableDebug ()
- task.disableDebug ()
- task.debugMsg ( obj )
- task.debugBreak ( obj )
These four calls lets you enable/disable the debug functions. When the
debugMsg is called, the obj parameter is sent to the debugger console for
display and the AL continues. The debugBreak call is the same as debugMsg only
the AssemblyLine will suspend and wait for a stop or continue command from the
debug console.
task.enableDebug ();
task.debugMsg ("We are now starting up ...");
task.disableDebug ();
task.debugBreak (" This call has no effect since debug is disabled ");
task.enableDebug ();
task.debugMsg ( conn );
task.debugMsg ( work );
task.debugBreak ( " This call will hang waiting for a continue/stop ");
// We will get here is the debug console says continue ...
PS! If you have the debug flag set for your Connector and debugging is
enabled, then you will get a break before and after every hook. The break will
show the hook name, the working entry and the Connector entry is present. |