Binding a Set of Classes XmlSeeAlso Mapping a Value Class to a Schema Type XmlType

Using JAXB Data Binding 5-13 For more information, see the javax.xml.bind.annotation.XmlRootElement Javadoc at http:download.oracle.comjavaee5apijavaxxmlbindannotatio nXmlRootElement.html . An example is provided in Section 5.4.1, Example of JAXB Annotations.

5.4.6 Binding a Set of Classes XmlSeeAlso

The XmlSeeAlso annotation binds a list of classes when binding the current class. The following table lists the optional element that can be passed to the XMLRootElement annotation.

5.4.7 Mapping a Value Class to a Schema Type XmlType

The XmlType annotation maps a class or enum type to an XML Schema type. The type can be a simple or complex type. The annotation can be specified for the following Java program elements: ■ Top-level class ■ Enum type The XmlType can be specified with the XmlRootElement see Section 5.4.5, Mapping a Top-level Class to a Global Element XmlRootElement and XmlAccessorType see Section 5.4.2, Specifying Default Serialization of Fields and Properties XmlAccessorType Annotation annotations. The following table lists the optional elements that can be passed to the XmlType annotation. For more information, see the javax.xml.bind.annotation.XmlType Javadoc at http:download.oracle.comjavaee5apijavaxxmlbindannotatio nXmlType.html . An example is provided in Section 5.4.1, Example of JAXB Annotations. namespace Namespace of the XML element. By default, the namespace is derived from the package of the class. Table 5–10 Optional Element for XmlSeeAlso Annotation Element Description value List of classes that JAXB uses when binding the current class. Table 5–11 Optional Elements for XmlType Annotation Element Description name Name of the XML Schema type to which the class is mapped. namespace Name of the target namespace of the XML Schema type. By default, the target namespace to which the package containing the class is mapped. propOrder List of JavaBean property names defined in a class. The list defines an order for the XML Schema elements when the class is mapped to an XML Schema complex type. Each name in the list is the name of a Java identifier of the JavaBean property. All of the JavaBean properties must be listed. Table 5–9 Cont. Optional Elements for XmlRootElement Annotation Element Description 5-14 Getting Started With JAX-WS Web Services for Oracle WebLogic Server

5.5 Customizing XML Schema-to-Java Mapping Using Binding Declarations