WebSphere Enterprise Service Bus for z/OS, Version 6.2.0 Operating Systems: z/OS


Overriding a Service Data Object to Java conversion

Sometimes, the conversion the system creates between a Service Data Object (SDO) and a Java™ type object may not meet your needs. Use this procedure to replace the default implementation with your own.

Before you begin

Make sure that you have generated the WSDL to Java type conversion using either WebSphere® Integration Developer or the genMapper command.

About this task

You override a generated component that maps a WSDL type to a Java type by replacing the generated code with code that meets your needs. Consider using your own map if you have defined your own Java classes. Use this procedure to make the changes.
Procedure
  1. Locate the generated component. The component is named java_classMapper.component.
  2. Edit the component using a text editor.
  3. Comment out the generated code and provide your own method.

    Do not change the file name that contains the component implementation.

Example

This is an example of a generated component to replace:
	private Object datatojava_get_customerAcct(DataObject myCustomerID, 
				String integer) 
{

		// You can override this code for custom mapping.
		// Comment out this code and write custom code.

		// You can also change the Java type that is passed to the 
		// converter, which the converter tries to create. 


		return SDOJavaObjectMediator.data2Java(customerID, integer) ; 
	
}

What to do next

Copy the component and other files to the directory in which the containing module resides, and either wire the component in WebSphere Integration Developer or generate an enterprise archive (EAR) file using the serviceDeploy command.

task Task topic

Terms of use | Feedback


Timestamp icon Last updated: 21 June 2010


http://publib.boulder.ibm.com/infocenter/dmndhelp/v6r2mx/topic//com.ibm.websphere.wesb620.zseries.doc/doc/tdev_overwsdltojavaconv.html
Copyright IBM Corporation 2005, 2010. All Rights Reserved.
This information center is powered by Eclipse technology (http://www.eclipse.org).