home *** CD-ROM | disk | FTP | other *** search
/ Computer Buyer 1998 June / dpcb0698.iso / Internet / Demon / IEXPLORE / IEAKJAVA.EXE / RCDATA / CABINET / JAVADBG.TXT < prev    next >
Text File  |  1997-01-31  |  5KB  |  117 lines

  1. ActiveX debugger support for the Microsoft Virtual Machine for Java
  2. ===================================================================
  3.  
  4.  
  5. ActiveX Debugging Mode
  6. ----------------------
  7.  
  8. This ActiveX debugger implementation runs in a special mode of the Microsoft
  9. Virtual Machine for Java that must be enabled at startup.  You can enable that
  10. mode by running "SetDebug.exe", as described in the next section.  ActiveX
  11. debugging enables the ActiveX debugger under both Internet Explorer and JView.
  12.  
  13. The ActiveX debugging mode of the VM is enabled by the existence of a registry
  14. key: "HKEY_LOCAL_MACHINE\Software\Microsoft\Java VM\ActiveXDebug".
  15.  
  16. This mode of the VM has two side effects that reduce the VM's performance:
  17.  
  18.     1) The just-in-time Java compiler is disabled.
  19.  
  20.     2) A debugger-instrumented bytecode interpreter loop is used.
  21.  
  22. To improve normal performance, you may wish to only enable the VM's ActiveX
  23. debugging mode while debugging Java classes.
  24.  
  25.  
  26. SetDebug.exe
  27. ------------
  28.  
  29. A utility app called SetDebug.exe is provided to enable / disable the ActiveX
  30. debugging mode of the VM, and to add / remove path elements from the source
  31. path.  SetDebug is installed in the Windows directory.
  32.  
  33. Invoking "SetDebug", without any arguments, displays a dialog box that allows
  34. you the enable / disable the ActiveX debugging mode of the VM.  It creates or
  35. deletes the ActiveXDebug registry key.
  36.  
  37. "SetDebug -?" displays a description of SetDebug's command line options:
  38.  
  39.     Usage:
  40.     -d              Disable ActiveX debugging for Java.
  41.     -e              Enable ActiveX debugging for Java.
  42.     -p <path>       Append <path> to the Java source path.
  43.     -r <path>       Remove <path> from the Java source path.
  44.  
  45. E.g., "SetDebug -p c:\Sources" appends the "c:\Sources" path to the source
  46. path. "SetDebug -r c:\Sources" removes it.
  47.  
  48.  
  49. Java Source Code
  50. ----------------
  51.  
  52. Source code for most of the Java system classes is included in this release.
  53.  
  54. The VM can read the Java source code from the classes.zip file just like it
  55. reads the Java classes from that file.  There is no need to unzip the
  56. classes.zip file, unless you wish to view the system classes' source code
  57. outside the debugger.
  58.  
  59. The VM searches for the source code for Java classes similar to the way that it
  60. searches for class files.  The VM first searches the source path, followed by
  61. the class path, for a source file.  Source code for a class must be located in
  62. the same package location as the class.  This does not necessarily mean the
  63. same container.  E.g., if you have your class path set to include the
  64. "c:\Classes" directory, and your source path set to include the "c:\Sources"
  65. directory, the VM could find the foo.Bar class as "c:\Classes\foo\Bar.class",
  66. and Bar's source code in "c:\Sources\foo\Bar.java".
  67.  
  68. The VM reads the source path from the "SourcePath" string value of the
  69. "HKEY_LOCAL_MACHINE\Software\Microsoft\Java VM" registry key.  The VM reads the
  70. class path from the "ClassPath" string value of the same key.  The source path
  71. value can be manipulated using SetDebug, as described in the previous section.
  72.  
  73.  
  74. Debugger
  75. --------
  76.  
  77. The debugger comes up with the Java class tree view fully expanded.  You can
  78. expand or collapse package views by clicking on the plus / minus sign to the
  79. left of a package name.
  80.  
  81. The debugger can still break and step in methods for which it does not have
  82. source code, e.g., when you invoke Internet Explorer->Edit->Break at Next
  83. Statement.  No source code or bytecode disassembly is displayed.  If you can't
  84. tell where you are, look at the Call Stack window.
  85.  
  86. In can be difficult to tell whether the debuggee is in a running state or in a
  87. break state from the debugger.  The Call Stack window will display "<Running>"
  88. while the debuggee is executing, and a call stack when the debuggee is stopped
  89. in the debugger.  Also, the toolbar execution buttons are disabled while the
  90. debuggee is executing, and enabled when the debuggee is stopped in the
  91. debugger.
  92.  
  93.  
  94. Immediate Window
  95. ----------------
  96.  
  97. The "JAutoExp.dat" file installed in the Windows directory allows you to
  98. customize the way Java classes are displayed in the Immediate window.  See that
  99. file for details.
  100.  
  101. You cannot evaluate expressions that include Java methods in the Immediate
  102. window.
  103.  
  104.  
  105. Thread List Window
  106. ------------------
  107.  
  108. The Thread List window in the debugger may get out of sync with the threads
  109. executing in the Java VM.
  110.  
  111.  
  112.  
  113.  
  114. The issues listed above will be addressed in future releases of the Microsoft
  115. Virtual Machine for Java and the Microsoft ActiveX Debugger.
  116.  
  117.