The completed Java source code for the jcdUpdate Collaboration appears as follows:
package prjDB2_JCDjcdALL;
public class jcdUpdate
{
public com.stc.codegen.logger.Logger logger;
public com.stc.codegen.alerter.Alerter alerter;
public com.stc.codegen.util.CollaborationContext collabContext;
public com.stc.codegen.util.TypeConverter typeConverter;
public void receive( com.stc.connector.appconn.file.FileTextMessage input, com.stc.
connector.appconn.file.FileApplication FileClient_1, otdDB2.OtdDB2OTD otdDB2_1 )
throws Throwable
{
FileClient_1.setText( "Updating the Rate and Last_update fields .. " );
FileClient_1.write();
otdDB2_1.getDB_EMPLOYEE().update( input.getText() );
while (otdDB2_1.getDB_EMPLOYEE().next()) {
otdDB2_1.getDB_EMPLOYEE().setRATE( new java.math.BigDecimal( "22.2" ) );
otdDB2_1.getDB_EMPLOYEE().setLAST_UPDATE( java.sql.Date.
valueOf( "2006-06-06" ) );
otdDB2_1.getDB_EMPLOYEE().updateRow();
}
FileClient_1.setText( "Update Done." );
FileClient_1.write();
}
}
|
The above code has been wrapped for display purposes.
For your next step, see Creating the Connectivity Maps .