Brief introduction
In addition to the traditional Enterprise JavaBeans (EJB) interface, the Java messaging Service (JMS) API, REST interface, and Web services APIs have recently been added. The pros and cons of these APIs are discussed by the comparison of the programming interfaces for interacting with business processes and human tasks.
The Web services API, introduced in version 6.0.2 of the WebSphere process Server, provides rich functionality for building client applications that interact with business processes and human tasks. Specifically, it provides the following features:
Ability to communicate with any run-time environment that supports WEB service invocations, including microsoft®.net environments.
Exposes the underlying call point as a Web service.
Better isolate clients and servers.
You can take advantage of existing industry patterns and powerful XML tools and runtimes.
With the EJB API, you can use the remote artifact loader to load existing artifacts from a remote server into your application. It hosts the artifacts installed on the server and makes them available to remote artifact loader clients in the same or other calculated cells. The client can then query or load the artifact from the remote Artifact Loader server.
However, the WEB services API does not support RAL, so there must be an appropriately formatted input data pattern, output data schema, and variable pattern on the client. For this issue, the Java architecture for XML Binding (JAXB) provides an easy way to bind XML schemas to representations in Java code. This allows developers to easily incorporate XML data and processing functionality into a Java application without having to learn more about the XML itself.
This article is not a JAXB tutorial, but rather a discussion of how the JAXB development and run-time Environment simplifies mapping XML schema definitions (XSD) to Java. This article also discusses the Run-time attributes required to dynamically generate a basic user interface at run time through the JAXB runtime and Java reflection.
Java Architecture for XML Binding (JAXB)
You can represent the business domain objects and their structural relationships through an XML schema. JAXB introduces the concept of data binding, which is the corresponding relationship between XML schemas and Java classes.
The JAXB Schema compiler creates Java classes and interfaces (typically executed at development time) based on the structure of the XML schema. At run time, the JAXB library is used for marshalling and deserialization. Grouping (marshalling) is the process of converting one or more Java objects into XML documents, and the reverse grouping (unmarshalling) is the reverse process of creating Java objects from XML, as shown in Figure 1.
Figure 1. JAXB element