@echo off
cd ..
echo Together includes a debug feature that helps you to debug your code. Debugging
echo of Together's component modules (formerly called scripts) requires some special
echo tricks.
echo.
echo This batch file runs an example project illustrating Together module debugging
echo by Together itself. Run this batch file to start Together with the TestModule
echo project. This project contains Manifest.mf, TestModule.tpr and TestModule.java
echo (the same file as the module's example %TGH%/modules/com/togethersoft/modules/
echo tutorial/Lesson02.java) files. In the project tree are imported openapi.jar,
echo together.jar and all other directories and archives from the Together classpath
echo (for new project add all libraries using "File:Project properties:advanced:
echo classpath" from TGH/lib)
echo.
echo 1) First you must compile the TestModule.java class. In the diagram, right
echo click the TestModule class and in the context menu select "Tools:Compile". 
echo You will then have a file "TGH/out/com/togethersoft/modules/testModule/
echo TestModule.class".
echo.
echo 2) Before debugging you must select any breakpoint in the source code of our
echo TestModule. For example you can set a breakpoint on the first operator in the
echo run() method of class TestModule. The line with breakpoint is colored red. In
echo the example project the breakpoint should already be set. If not - right click
echo this operator and select "Toggle breakpoints" (or press F5). In the
echo "Breakpoints" pane you can change the breakpoint's options. If the breakpoint's
echo type is "invalid" remove it - this means that code was changed and this
echo breakpoint never occurs.
echo.
echo 3) Now start debugging. Select "Tools":"Run/Debug":"Run in Debugger" (or press
echo Shift-F9) to run the integrated debugger. You will be prompted "Enter class
echo name with main". Select default class "com.togethersoft.together.main" and
echo press Enter. You will start the second instance of Together. Open any project
echo in the second instance of Together (for example java/CashSales project). Open
echo a Diagram and select any object in the diagram (for example interface
echo IMakeCashSale).
echo.
echo 4) Now we have two instances of Together running:
echo - 1st Instance of Together: Together project for the module to be debugged
echo   ("TestModule" ) is opened; debugger is started; source files of TestModule
echo   are loaded into Together.
echo - 2nd instance of Together: Together project CasSales is opened; module
echo   "TestModule" will be executed in this instance
echo.
echo 5) Now you can debug module "TestModule". In the workspace of the second
echo instance of Together expand all modules to find "TestModule (module for debug
echo example)" module.
echo.
echo Right click this node and choose "Run". Execution will stop at the break point
echo in the run() method (note selected blue line in the first instance of Together)
echo You can trace over or into the blocks(F8/F7), methods and classes, you can
echo watch variables, run and stop process, view loaded classes etc.
echo.
echo The project contains an example watch with name "int i" contained the value of
echo the loop variable i. All available debugger features you can see in Together's
echo Help: "User's Guide: Part II. Developing with Together: 13.Using the Integrated
echo Debugger".
echo.
echo You can change all debugger configuration options in the Options dialog:
echo ("Options" : "Debugger").
echo.
echo 6) To stop the debugger select "Resume program". Note: During debugging the
echo debugged process can not independently update the screen. Thus it can be appear
echo that the process hangs.
pause
@echo on
Together.exe ../modules/com/togethersoft/modules/testModule/TestModule.tpr