Java Code Generation Settings

When you generate Java code for an XSLT document, you need to specify

  • The target directory in which you want the Java code created. c:\temp\myJavaCode, for example. If the directory you name does not exist, Stylus Studio creates it when you run the Java Code Generation wizard. The default is a \sources directory, which is created where you installed Stylus Studio when you generate the code, c:\Program Files\Stylus Studio\sources, for example.
  • Optionally, a package name. If you specify a package name, this name is used for a subfolder created in the target directory you specify. If you specify myPackage as the package name, for example, the generated code is written to c:\temp\myJavaCode\myPackage. (Though optional, it is considered good practice to create a package name.)
  • The class name. Stylus Studio also uses the class name for the .java file created by the Java Code Generation wizard. For example, if you provide the name myClass, Stylus Studio creates c:\temp\myJavaCode\myPackage\myClass.java.

In addition, you can specify whether or not you want to

  • Create the class as a public class
  • Include the main(String[ ] args) method
  • Add the generated code to the current project

All of these options are selected by default.

Tip

 

If you choose to add the generated code to the project, it creates a folder using the package name you specify and places the .java file in that folder. If you do not specify a package name, the .java file is added directly below the project root in the Project window.

Learn XSLT and XQuery Profiling

Stylus Studio's Profiler can help you evaluate the performance of your XQuery and XSLT. Automatically generated, customizable, easy-to-read HTML reports provide insight into performance bottlenecks.

FLWOR - An Introduction to the XQuery FLWOR Expression

An XQuery FLWOR Tutorial, covering an introduction to the main constructs of the XQuery FLWOR expression, including: For, Let, Where, Order By, and Return. Written by the W3C's Dr. Michael Kay.

Oil, Gas & Electric Companies That Use Stylus Studio

Oil, gas & electric companies know a good resource when they see it. That's why they use Stylus Studio as their #1 XML resource. Come see which of these top oil, gas & electric companies are conserving their time and labor with Stylus Studio.

DOM - The Document Object Model

The Document Object Model (DOM) is a cross-platform interface for parsing and manipulating XML. Learn how Stylus Studio supports DOM in our XML Pipeline and other XML parsing tools.

Stylus Most Wanted

 
Free Stylus Studio XML Training:
W3C Member