O'Reilly logo

Java & XML Data Binding by Brett McLaughlin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Castor

Here is the output from the Castor generation tool:

[bmclaugh@aragorn]$ java org.exolab.castor.builder.SourceGenerator

Usage: -i filename 
      [-package package-name] 
      [-dest dest-dir] 
      [-line-separator ( unix | mac | win)] 
      [-f ] 
      [-h ] 
      [-verbose ] 
      [-nodesc ] 
      [-types types] 
      [-type-factory classname] 
      [-nomarshall ] 
      [-testable ]

Table A-3 details each option and its use.

Table A-3. Castor SourceGenerator options

Flag

Value

Purpose

-i

XML Schema to parse

Specify the schema constraint set to Castor to generate class from.

-package

Java package

Set package for generated classes.

-dest

Destination directory

Set the directory to put generated classes in.

-line-separator

unix or mac or win

Set line separator to use for a specific platform; by default, this will attempt to autodetect your platform.

-f

N/A

Hide nonfatal warnings in class generation.

-h

N/A

Display a help screen and command usage.

-verbose

N/A

Display extra information about the class generation process.

-nodesc

N/A

Prevent creation of class descriptors.

-types

Type for collections

Specify the collection type to use.

-nomarshall

N/A

Prevent generation of marshal( ) methods on generated classes.

-testable

N/A

Set up class to be used by Castor testing framework (included with Castor).

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required