Java classes can be used as source and target types for transformations. Also, business process variables can be created from Java classes.
However, not all the fields that can make up a Java class are supported. This section describes which fields of a Java class are supported.
When you use a Java class or primitive in a transformation, WebLogic Integration converts it into an internal representation of XML Schema data types. Java fields that are not supported are ignored. WebLogic Integration then uses this internal representation to transform your Java classes to and from XML and non-XML (MFL) documents
Note: This internal representation of the XML Schema is not exposed in WebLogic Workshop.
Note: The mapper functionality of WebLogic Workshop will only display the fields of a Java class that are supported.
For a Java class to be used in WebLogic Integration, it must first be available in the WebLogic Workshop project. To learn more about including Java class in your project, see Using Existing Applications.
Note: Java interfaces and abstract Java classes are supported as source or target types for a transformation but you will not be able to execute your transfomation in the Test View. However, a transformation with a Java interfaces and/or abstract Java classes as source or target types can be invoked from a business process (JPD) without error.
Java classes are converted using the following procedure:
All the Java fields that can be mapped are converted to the appropriate XML Schema elements in the new XML Schema. If a field cannot be mapped it is ignored. To learn more, see the following table.
The following table describes the supported fields of Java classes and how these fields are converted to the internal XML Schema representation of the Java class. Also, the XML Schema data type can be converted back to the Java field unless otherwise noted.
For example, Java primitive float type is converted to a XML Schema float type. |
|
To learn more see XMLBeans Support for Built-In Schema Types. |
|
xsd:sequence of specified data type For example, an array of Java integers is converted to a XML sequence of integers. |
|
java.util.Collection and classes that implement the interface |
Note: You cannot convert from XML back to a Collection nor any class that implements the Collection interface because the data type of objects inside the Collection implementing class is not known. Use an array of a specific Java type as a target instead. |
Note: Static member variables are not converted.
Note: Final instance member variables (constants) are not converted.
public class TestSimpleTypes { private boolean testBool; public boolean getTestBool(){ return testBool; } public void setTestBool(boolean b){ testBool = b; } }
To learn more about creating Java class variables in business processes, see Creating Variables.
To lean more about using Java classes as input or output parameters in transformations, see Using Java Classes in Transformations.
![]() |
![]() |