schemagen

You can use the schemagen tool and commands to generate a schema for every namespace that’s referenced in your Java classes.

Synopsis

schemagen [ options ] java-files
options

The command-line options. See Options for the schemagen Tool.

java-files

The Java class files to be processed.

Description

The schema generator creates a schema file for each name space referenced in your Java classes. Currently, you can’t control the name of the generated schema files.

Start the schema generator with the appropriate schemagen shell script in the bin directory for your platform. The current schema generator can process either Java source files or class files.

schemagen.sh Foo.java Bar.java ...
Note: Writing schema1.xsd

If your Java files reference other classes, then those classes must be accessible on your system CLASSPATH environment variable, or they need to be specified in the schemagen command line with the class path options. If the referenced files aren’t accessible or specified, then you get errors when you generate the schema.

Options for the schemagen Tool

-d path

This option sets the location where the schemagen command places processor-generated and javac-generated class files.

-cp path or -classpath path

This option sets the location where the schemagen command places user-specified files.

-encoding encoding

This option specifies the encoding to use for apt or javac command invocations.

-episode file

This option generates an episode file for separate compilation.

-disableXmlSecurity

This option disables XML security features for usage on XML parsing APIs.

-version

This option displays release information.

-fullversion

This option displays full version information.

-help

This option displays a help message.