Debugging Java Extensions

The XSLT/XQuery debugger does not step into Java classes that are configured as XSLT/XQuery extensions of the transformation. To step into Java classes, inspect variable values, and set breakpoints in Java methods, you can set up a Java debug configuration in an IDE (such as the Eclipse SDK) as described in the following steps:

  1. Create a debug configuration.
    1. Set at least 256 MB as heap memory for the Java virtual machine (recommended 512 MB) by setting the -Xmx parameter in the debug configuration (for example, -Xmx512m).
    2. Make sure the [OXYGEN_INSTALL_DIR]/lib/oxygen.jar file and your Java extension classes are on the Java classpath.
      The Java extension classes should be the same classes that were set as an extension of the XSLT/XQuery transformation in the debugging perspective.
    3. Set the class ro.sync.exml.Oxygen as the main Java class of the configuration.
      The main Java class ro.sync.exml.Oxygen is located in the oxygen.jar file.
  2. Start the debug configuration.
    Now you can set breakpoints and inspect Java variables as in any Java debugging process executed in the selected IDE (Eclipse SDK, and so on.).

Was this helpful?