202 IBM Branch Transformation Toolkit 5.1 Migration and Usage Guidelines
and Appendix B, “Setting up a Branch Transformation Toolkit sample
application” on page 493).
The resulting file structure in the WEB-INF folder should look as shown in
Figure 6-52.
Figure 6-52 WEB_INF folder for BaseSampleWeb
Java client
1. To configure the build path of the DSE_SampleApplicationClient project,
right-click the project and open its Properties window. Select Java Build
Path from the left panel.
In the Libraries tab, click Add JARs. Expand the BaseSample project and
select the following JAR files:
dseb.jar
dsecsm.jar
dsecss.jar
dsed.jar
–dseflp.jar
dseflpeclt.jar
–dsegb.jar
dsejxpsvc.jar
dsesci.jar
Chapter 6. Post-migration activities 203
dsesym.jar
–dsetde.jar
In the Libraries tab, click Add Variable. Choose WAS_V5_XERCES from the
list and click OK. See Figure 6-53
Figure 6-53 Java build path for client application
2. Modify the OpenDesktop.java class in the com.ibm.dse.samples.appl
package of the DSE_SampleApplicationClient project. Change the initial
value of the variable iniPath to
http://127.0.0.1:9080/BaseSampleWeb/dse/dse.ini.
See Figure 6-54 on page 204
204 IBM Branch Transformation Toolkit 5.1 Migration and Usage Guidelines
Figure 6-54 Set configuration file path
3. Configure the UserDefineJar project. Right-click the UserDefineJar project to
bring its Properties window.
Select Java Build Path from the left panel. In the Libraries tab, click Add
JARs.In the pop-up window, expand the BaseSample project to choose the
bttbase.jar file. Click OK to add. See Figure 6-55 on page 205.
Chapter 6. Post-migration activities 205
Figure 6-55 Add JARs to build path for client application
Modify the HostField.java class in the com.ibm.dse.samples.appl package.
Change the following line:
import com.ibm.dse.base.*;
The line should appear as:
import com.ibm.btt.base.*;
Add two methods in this class:
public void writeExternal(java.io.ObjectOutput s) throws
java.io.IOException {
super.writeExternal(s);
s.writeUTF(hostIdentifier);
}
206 IBM Branch Transformation Toolkit 5.1 Migration and Usage Guidelines
/**
* Invokes the object creation from an ObjectInput.
* @param s java.io.ObjectInput
* @exception java.io.IOException.
* @exception java.lang.ClassNotFoundException.
*/
public void readExternal(java.io.ObjectInput s) throws java.io.IOException,
java.lang.ClassNotFoundException {
super.readExternal(s);
//hostIdentifier
hostIdentifier = s.readUTF();
}
Modify the HostDecorator.java class in the com.ibm.dse.samples.appl
package. Change the following line:
import com.ibm.dse.base.*;
It should appear as follows:
import com.ibm.btt.base.*;
Modify the HostStringFormat.java class in the com.ibm.dse.samples.appl
package. Change the following line:
import com.ibm.dse.base.*;
It should appear as follows:
import com.ibm.btt.base.*;
Change the definition of the method formatField( ) in this class:
public String formatField( DataField aDataField) throws
com.ibm.btt.base.DSEInvalidClassException { ... }
Surround the statement aDataField.setValue(tmpString); with try/catch
block as follows:
try {
aDataField.setValue(tmpString);
} catch (Exception e) {
e.printStackTrace();
}
4. Add the Base Sample Application to the test environment.
Since you use the WSAD test environment to deploy the BaseSample server,
add the Base Sample Application.
Change to the Server perspective. Right-click the BaseSample server in the
Server Configuration panel. Select Add and remove projects in the pop-up
menu. In the next window, select Base Sample project from the list in the left

Get IBM Branch Transformation Toolkit 5.1 Migration and Usage Guidelines now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.