An XML Schema gets compiled to Java classes representing the DOM structure of the schema using the JAXB compiler. To compile the catalog.xsd XML Schema, select File | New | Other, and select JAXB Classes from Schema under JAXB, as shown in the following screenshot:
In the New JAXB Classes from schema window, select the JAXB project—JAXBEclipse and click on Next, as shown in the following screenshot:
In the Configure
JAXB class generation dialog box, specify JAXBEclipse/src
in the Source folder field, specify the package name as jaxbeclipse
in the Package field, and click on Next, as shown in the following screenshot:
In the Classes Generation Options dialog box, check the Use strict validation and Treat input as XML schema checkboxes and click on Next, as shown in the following screenshot:
In the Classes Generator Extension Configuration dialog box, specify -target 2.1 in the Additional arguments field. Click on Finish: