Developing Java CAPS Projects

Collaboration Definitions

Figure 16 Collaboration Definition Icon

Image of a Java Collaboration Definition icon.

Collaboration Definitions define how data should be processed and routed between Project components, how databases should be queried in response to requests, and how APIs to one or more applications should be invoked. The external data formats that characterize the input and output data structures in a Collaboration Definition are described by Object Type Definitions (OTDs).

A Collaboration will typically receive a message containing the external representation of a particular OTD. It will use the unmarshal method of an instance of that OTD to parse the data and make it accessible though the hierarchical data structure. Then it will perform some operation— for example, copying parts of the data to another OTD instance. Finally, it will invoke the marshal method on the other OTD instance to render the contents of its data structure as a single, serialized data stream for further transport.

At run time, an OTD instance is accessed directly from Java, using accessors resembling JavaBeans. Each of the nodes comprising the hierarchy of the data structure has a set of properties with get and set methods.

A Java-based Collaboration Definition provides a single operation that can be invoked from a Business Process. You can create multiple methods in a Java-based Collaboration Definition, but the additional methods can only be invoked from within the Collaboration Definition.