Main Page

Previous Section Next Section

JAXB Architecture

JAXB architecture uses a design similar to the other JAX APIs . Developers use standard interfaces and classes provided by the specifications, and vendors provide the implementation. Figure 13.1 shows the overall architecture. Developers write application code and business logic that uses Java classes and interfaces representing XML constructs. These classes are generated from XML schemas using JAXB-provided tools.

Click To expand
Figure 13.1: JAXB architecture

When the code must unmarshall XML supplied by some external entity, such as a Web service, the JAXB API is invoked to unmarshall the XML, and the data represented therein is populated in its corresponding Java classes.

To change the Java classes to the corresponding XML representation, developers invoke the JAXB API, and the Java classes are marshalled into the schema-compliant XML format.

Previous Section Next Section

JavaScript Editor Java Tutorials Free JavaScript Editor